6Fifty Shades of Dorian Gray

The Selfies of Dorian Gray

Were we to reinvent Dorian Gray for the twenty-first century, the young cad about town would now have as many ways to strut his stuff in the virtual world as in the real. Gray might now invite his friends to upload their artistic impressions of him to Pinterest, though as he would also surely delight in the possibilities of the digital self-portrait to shape his own aesthetic image on Instagram and Flickr. Lacking any need or desire to work for a living, Gray would most likely favor Facebook over LinkedIn and view Twitter as a perfect outlet for his bon mots and put-downs. In Gray’s manicured hands, each tweet would likely serve as the linguistic equivalent of a selfie, a knowing online pose to convey one’s attitude to the world and, especially, one’s social circle. In fact, because what we tweet and whom we follow can be so very revealing about our inner selves, a burglar who came upon Gray’s hidden “soul” portrait in the attic could scarcely learn more about the man’s true personality than any of his followers on Twitter. Our online personality is now as measurable as our carbon footprint and is as much a function of what we unthinkingly discard as what we lovingly flaunt.

In addition to some rather obvious statistics, such as how often we tweet, how many others we follow, and how many others follow us, we principally reveal ourselves in our choice of words. How often I refer to “I,” “me,” “myself,” “mine,” and “my” can tell you a good deal about my propensity for self-absorption, while a frequent use of “we” and “our” indicates a willingness to share either credit or blame. The frequency with which I use “you” or “your” is just as indicative of a desire to channel my feelings outward, so if I also show a partiality for negative words, this pairing of observables is strongly indicative of hostility. Frequent use of “LOL,” “OMG,” and the exclamation point reveals an excitable personality, while emoticons and hashtags such as #irony and #sarcasm make explicit not just my feelings but a playful stance toward the content of my own tweets. The use of complex sentence structures hinging on the logical connectives “if,” “but,” “yet,” and “therefore” suggests a capacity for analytical thinking, while frequent questions—especially those involving words of negative sentiment—offer a clue to a nervous disposition. Using simple linguistic criteria such as these in combination with an array of sentiment lexicons,1 James Pennebaker2 and his team at the University of Texas have developed a sentiment tool, linguistic inquiry and word count (LIWC) that can quantify an author’s personality along a range of dimensions, including positivity, anxiety, depression, anger, affability, social engagement, arrogance, enthusiasm, logicality, topicality, and self-absorption. An online version (at AnalyzeWords.com) allows users to affectively profile a Twitter personality of their choosing by entering the corresponding Twitter handle. Here is a screen-grab of an LIWC profile of @realDonaldTrump in June 2016:

10859_006_fig_001.jpg

Screen grab from http://analyzewords.com/index.php?handle=realdonaldtrump.

Trump’s profile, captured in the days following his acceptance speech to the Republican National Convention in Ohio in 2016, contains notes of arrogance, anger, and intense positivity and even suggests a certain logical structure to his argumentativeness. If none of this seems particularly surprising, this is, after all, the goal of a credible analysis. Trump’s anger was voluble and contagious, and the real estate tycoon is famously unrestrained by modesty when touting his acumen for making deals, picking wives, or fighting terrorists. Frequent uses of the mantra “Make America Great Again” also leavened his attacks on “crooked” Hillary to establish an online personality that was angry about the present but very positive about the future. But author profiling is not palm reading, even if each involves the measurement of different kinds of “life” line. Online personality is dynamic and diachronic, not static and synchronic; though one can discern a general disposition that persists over time, individual readings can reveal the effects of context. Consider Trump’s profile just a day after Hillary Clinton’s acceptance speech at the 2016 Democratic National Convention in Philadelphia, a speech during which Trump tweeted prolifically:

10859_006_fig_002.jpg

Trump remains upbeat in this profile, if less so than in the afterglow of his own speech, yet his anger levels spike as he devotes more energy to denouncing his rival than to expounding his own vision. So we see his attacks on Hillary become less analytical as he swaps logical structure for the pugilistic simplicity of insults. Online personalities as famously pungent as Trump’s are a magnet for satire, and one might well ask how good a job these phony Trump accounts do at capturing his volatile Twitter temperament. One non-bot satirist is @DonaldDrumpf, a human account whose name pokes fun at the Trump family’s immigrant history.

10859_006_fig_003.jpg

Screen grab from http://analyzewords.com/index.php?handle=donaldDrumpf.

@DonaldDrumpf aims to satisfy two completing goals: to mimic Trump’s barbed Twitter style while undercutting the content of his rhetoric.3 It achieves the latter by addressing topical issues, such as claims that Trump is Putin’s Manchurian candidate, while mocking Trump’s self-regarding origin story in tweets such as: “My father only left me a few measly million dollars. Now I have billions. Testimony to my ability to borrow. Drumpf 2016 #selfmademan.” At the same time, pitch-perfect word choice allows @DonaldDrumpf to echo the pugnacious Trump tone, and as shown in this AnalyzeWords profile, a preponderance of negative words such as “measly” pushes Drumpf’s perceived anger levels high into the red zone. While this is an assured act of Twitter ventriloquism, aspects of the satirist’s own comedic style will inevitably show through when delivering a comic message in the target’s voice. We see in the profile above that the satirist goes large on every measurable aspect of Trump’s personality—even upping the sensory dimension to lend him a touchy-feely sense of his own feelings—except for the two aspects that most clearly shine through in Trump’s own tweets: arrogance and positivity. And while a cutting irony is sometimes conveyed with a simple hashtag such as #selfmademan, the conflation into a single tweet of what we expect Trump to say and what we expect his critics to say often calls for an elaborate counterfactual logic, serving to boost Drumpf’s perceived analyticity to an artificially high level.

Now look at the profile of a satirical Trump Twitterbot named @DeepDrumpf:4

10859_006_fig_004.jpg

Screen grab from http://analyzewords.com/index.php?handle=donaldDrumpf.

Designed by MIT postdoctoral researcher Bradley Hayes, the @DeepDrumpf bot demonstrates the use of recurrent neural networks, specifically long short-term memory (LSTM) networks, to train a generative system on the speech patterns of a human exemplar, as found in, say, transcripts of one’s speeches and tweets. The experimental beat writers of the 1960s used the cutup method of Brion Gysin and William S. Burroughs to slice’n’dice the texts of other writers into novel arrangements that, one hopes, will preserve the themes of the original text while disrupting its inherent clichés. @DeepDrumpf uses the deep-learning technology of LSTM as its statistical answer to scissors and paste to achieve much the same ends: to cut transcripts of attested speech into training data so as to learn how to stick it all together again in resonant but strangely familiar ways. The dark irony of @DeepDrumpf is not planned with anything like the comedic rigor of @DonaldDrumpf, but in a testament to the cutup method, its outputs can seem just as disruptive of its target’s clichés as anything written by a human satirist. The following tweet, one of @DeepDrumpf’s most retweeted and favorited, fuses several Trumpian themes—from the anti-immigrant wall to “You’re fired!” to “job creation“ in a way that comically undercuts them all: “I can destroy a man's life by firing him over the wall. That's always been what I'm running, to kill people and create jobs. @HillaryClinton.” Unlike the very human @DonaldDrumpf, which strives for the comedic consistency of a human satirist so that every tweet is worthy of retweeting, @DeepDrumpf is a more hit-and-miss affair. Yet because we do not hold bots to the same standards as human creators on Twitter, we will gladly engage with the bot in a co-creative process of collaborative filtering by endowing some outputs with collective acclaim with our retweets and favorites. Though human creators benefit from the same word-of-mouth marketing by avid followers, we don’t want our bots to simply ride on someone else’s coattails but to become an active part of the co-creation process. Like Duchamp recognizing the aesthetic merits of a lowly object that many others have scorned, we become connoisseurs of the generative objet trouvé when we acclaim these accidents of bot meaning.

As bots go, @DeepDrumpf tends to—not inappropriately—run its mouth, in an effort to squeeze as much content into its bite-sized tweets as possible. Because its content is drawn from the disassembled and reconstituted tweets of its target, its outputs convey a magnified sense of Trump’s personality. As shown in the profile above, the bot lights up the board on all dimensions measured by AnalyzeWords, except for the sensory dimension. To judge by Trump’s own words, he is not one to articulate his own feelings at length or in public, preferring to project feelings of love and admiration (for him) onto others while he gives a voice to their rage. In deciding which satirical account does a better job of capturing the personality of Donald Trump, it may seem odd to even imagine that a Twitterbot might have a personality at all. @DonaldDrumpf’s is essentially a blend of Trump’s and that of its human creator, while @DeepDrumpf’s personality is something else again, the exaggerated (yet undercut) personality of a digital über-Trump. In fact, every Twitterbot has a personality. It may be the personality of a raucous pet or a pet rock, but it is a personality nonetheless. How could any Twitterbot fail to have a personality, given that we unleash our bots onto a vast social network in which people judge the character of others by what and how they tweet? A Twitterbot may be an artificial entity, but each Twitterbot is an artificial social entity to boot.

A bot’s personality need not be as big as @DeepDrumpf’s to earn retweets, and to get a sense of the Twitterbot personality in aggregate, we can look to the profile of an account that serves as a popular hub for bot outputs. The following analysis paints a rather muted picture of the personality of @botALLY (or Lotte McNally):5

10859_006_fig_005.jpg

Screen grab from http://analyzewords.com/index.php?handle=botally.

This is an aggregate personality of milk and water, not piss and vinegar, though we can take some comfort from the observation that the average bot personality is, well, so average after all. This collective chill may suggest that bots of every emotional level can be found in more or less equal numbers on Twitter, though the general lack of analyticity also suggests that bot designers favor short and syntactically simple forms over long and complex alternatives. So @DeepDrumpf is an outlier on multiple fronts, most likely because it is intended to magnify the qualities of an already polarizing human rather than to showcase a personality that is truly its own. Yet even if most bot designers do not set out to imbue their creations with a human personality, a distinctive human-like personality can nonetheless emerge from even the simplest of design decisions, especially when those decisions concern the cutting and splicing of ready-made human content on Twitter. A case in point is Rob Dubbin’s popular @OliviaTaters bot, whose AnalyzeWords profile (from July 2016) is shown here:6

10859_006_fig_006.jpg

Screen grab from http://analyzewords.com/index.php?handle=oliviataters.

Olivia uses William S. Burroughs’s cutup method in much the same way that it is used by Darius Kazemi’s @twoheadlines: to splice two arbitrary tweets into one. But whereas @twoheadlines cuts up news headlines to produce new headlines, Olivia splices random Twitter musings to produce oddly engrossing brain farts. Olivia’s core algorithm, as described by Dubbin, is remarkably simple: the bot looks for hyperbolic tweets that use adverbs such as “totally” and “literally” to emphatically introduce a verb phrase, as in, “If I were leader of the Labour Party I would totally spend all my time at big public meetings in my honour” and “Freddie Mercury would totally fit into this too.” Splicing these tweets together at their adverbial pivot yields two new well-formed possibilities: “If I were leader of the Labour Party I would fit into this too” and “Freddie Mercury would spend all my time at big public meetings in my honour.” Because of their fondness for adverbs like totally, the inputs to the bot’s splicer are quite often the work of teenagers, or at least the young of heart, but Dubbin noticed that his bot’s outputs tend to smell like teen spirit too. A tightly constrained use of the cutup method thus resulted in a bot with a distinctive teenage personality that Dubbin named Olivia Taters, or, as writer Aaron Sankin dubs her, “America’s favorite robot teenager.”7

Though the Olivia bot gathers its raw materials from diverse and more-or-less random Twitter effusions that are united only in their use of particular adverbs, its personality is not the wishy-washy aggregate we see in @botALLY. Rather, as shown in the bot’s AnalyzeWords profile, she (both Dubbin and Sankin enthusiastically refer to the bot as a “she”) remains a well-drawn presence on Twitter. She exudes anger and affability, analyticity, and an awareness of her feelings and her environment, and she tempers occasional dark thoughts with a LOL excitability. Olivia pushes many of the AnalyzeWords needles in interesting directions where they provoke comparisons to other bots or indeed to other human Twitter users. This suggests that one Twitterbot might use the AnalyzeWords profile of another to cast judgment or offer advice, or to use a mechanical capacity for metaphorical description in ways that allow human speakers to navigate the social currents. Our bots might thus use pithy metaphors and figurative put-downs to articulate their similarities and their differences to both each other and to famous humans.

#LikeMe

By assigning a Twitter account to a specific point on each of eleven scales, AnalyzeWords effectively maps the account to a point in an eleven-dimension space. If we draw a line from the origin of this space (all zeroes) through this point, the resulting vector acts as a single representative needle for the personality of the account; as the personality changes—as its tweets become more or less angry, say, or more-or-less attuned to others—the needle will twitch about in the space. Now imagine the needles of all Twitter users, pointing in various directions and moving ever so slightly with each new tweet. When two needles seem to point in the same direction, leaving only a small angle between them in vector space, then we can say that the corresponding Twitter accounts are exhibiting highly similar personalities. As we saw previously, we need only measure the cosine of the angle between two vectors to estimate how similar they are, since the cosine of a 0° angle is 1 and the cosine of a 180° angle is -1. Thus, to estimate the similarity of @realDonaldTrump to @DonaldDrumpf or @DeepDrumpf, or to any bot of your choosing, we can simply measure the angle between their AnalyzeWords vectors.

As an example, let’s compare the AnalyzeWords profile of @realDonaldTrump to that of @Lord_Voldemort7. Our reasons for this choice will become clear soon enough but let’s proceed on the presumption that the tweets of a president (or a presidential candidate) will be quite unlike those of someone pretending to be the self-proclaimed Dark Lord. Sampled in mid-July 2016, @realDonaldTrump’s profile produced this vector:

<Analytic: 54, Angry: 65, Arrogant: 71, Depressed: 55, In-the-moment: 47, Personable: 51, Plugged In: 47, Sensory: 47, Spacy: 50, Upbeat: 55, Worried: 67>

To distinguish high from low scores for each dimension, as each has an opposing semantic interpretation—a low score for Angry actually means Calm, after all—we subtract 50 from each value, so that dimensions run from 50 to +50 instead:

<Analytic: 4, Angry: 15, Arrogant: 21, Depressed: 5, In-the-moment: −3, Personable: 1, Plugged In: −3, Sensory: −3, Spacy: 0, Upbeat: 5, Worried: 17>

The needles of opposing personalities will point in very different directions. Because we want to normalize each vector so that its length in our vector space is 1, we first calculate the length of the vector using the standard Euclidean metric, the square root of the sum of the squares of each dimension, which gives 32.388. We can now normalize the vector by dividing each dimension by this length, to give:

<0.124, 0.463, 0.648, 0.154, −0.093, 0.031, −0.093, −0.093, 0.0, 0.154, 0.525>

When we now calculate the length of this normalized vector using the Euclidean metric, we see that it has a unit length of 1.0. By way of comparison, the profile for @OliviaTaters shown in our earlier screen grab yields this normalized vector:

<0.408, 0.436, 0.338, 0.155, 0.521, 0.211, −0.056, 0.296, 0.31, 0.042, −0.028>

And when normalized, the AnalyzeWords profile for @Lord_Voldemort7 yields:

<0.266, 0.434, 0.374, .072, −0.012, 0.229, −0.012, −0.29, 0.157, −0.314, 0.579>

To calculate the cosine of the angle between any two vectors of unit length, we just have to calculate the dot product of the two by summing the product of the corresponding dimensions of each vector. So the dot product of the vectors for @realDonaldTrump and @OliviaTaters is calculated to be 0.423 (that’s the sum of 0.124 × 0.408 + 0.463 × 0.436 + 0.648 × 0.338 + . . . + 0.525 × −0.028), whereas for @realDonaldTrump and @Lord_Voldemort7, it is 0.7795. Recall that the more similar the AnalyzeWords profiles of two accounts, then the closer their vectors will be in eleven-dimensional space and the nearer the value will be to 1 (conversely, the more dissimilar the profiles, the nearer it will be to −1). By this reckoning, 0.423 suggests just a modest resemblance, while 0.7795 is indicative of deep similarities between @realDonaldTrump and @Lord_Voldemort7. In fact, if we use AnalyzeWords.com to profile 695 of the most followed accounts on Twitter (as ranked by TwitterCounter.com), we find that @Lord_Voldemort7 is the closest of them all to @realDonaldTrump in our vector space, with the profile of Family Guy creator and sharp-tongued satirist Seth MacFarlane racking up a similarity of 0.6237. Conversely, pop singer Carly Rae Jepsen (@carlyraejepsen) is the most dissimilar of all the 695 profiles, exhibiting a (dis)similarity of −0.7197 to @realDonaldTrump. In vector space terms, the personality needles of these celebrity tweeters resolutely point in opposite directions.

AnalyzeWords derives its eleven-dimensional analysis from a sampling of recent tweets that comprise a thousand or so words, but as we saw in the previous chapter, we can treat this sample as a single text block and use latent Dirichlet allocation (LDA) to map it into a 100-dimensional topic space to obtain a 100-dimension vector for comparison purposes.8 We can, for example, reuse the topic model that we built from the @MetaphorMirror newspaper corpus to give us a sufficiently nuanced space in which to characterize our sampled tweets. The mechanics of similarity measurement remain exactly the same whether we use vectors with 3, 11, or 100 dimensions, though LDA vectors allow us to compare two Twitter accounts on the substance of their tweets rather than on the affective resonance of their personalities. So while @realDonaldTrump and @Lord_Voldemort7 show similar temperaments, we should expect their tweets to touch on very different topics. In fact, when we use our LDA model to find the most similar match to @realDonaldTrump in the top 695 Twitter accounts, it is the vector of talk-show host Stephen Colbert (@stephenAtHome), famed for his satirical take on right-wing politics, that yields the best cosine similarity: 0.732. The fact that one user is deeply ironic and the other acutely literal matters little to topic analysis, which sees shades of both in tweets such as: “Been watching the DNC, and I’m detecting a strong anti-Trump bias. We’ll unpack everything tonight on a live #LSSC!” In contrast, the LDA vector for @DonaldDrumpf yields a cosine-similarity score of just 0.536, while that of @DeepDrumpf scores even lower, at 0.492.

Just as the perceived temperament of a Twitter user may change with each new tweet, so too can the topical substance of these tweets. Indeed, depending on when we (or our bots) profile a given account, we can expect to see changing affinities with other accounts, prompting a metaphor-generating bot to propose different comparisons at different times. If these periodic changes in sentiment and topic are the Twitter equivalent of the weather, this virtual weather is just as rich a vein of conversation for Twitterbots as real weather is for real people. If a target such as @realDonaldTrump can sound like @LordVoldemort7 at time t and more like @OliviaTaters or even @HillaryClinton at time t + 1, then a Twitterbot with a memory for what it has said in the past can do more than generate new comparisons in new contexts, it can generate meta-metaphors and self-reflective contrasts too. Like the moldering picture in Dorian’s attic, our bots’ tweets can paint a searing portrait of another Twitter user, whether a human or a bot, if not to capture its “soul” then to chart the evolution of its apparent online personality.

#JudgeMe

The Irish writer Brendan Behan once defined blasphemy as “the comic verse of belief.”9 Only a believer has the conviction to take a yardstick to another’s back, and a yardstick like AnalyzeWords supports a welter of comic abuses. Its eleven dimensions may paint a low-res picture of a Twitter user, yet with the right framing, these are enough to cast righteous scorn on the brains, heart, and senses of a judgmental bot’s comedic targets. Let’s assume that other Twitterbots are fair game for the uninvited criticisms of our automated critic, while human users must willingly opt in by tweeting a beckoning hashtag such as #JudgeMe. We can divide each dimension into four quanta of interest—Very Low, Low, High and Very High—with merely average ratings earning neither criticism nor praise. For each quantum of each dimension, we predefine an apt response for our bot as follows:

Emotional Style

Social Style

Thinking Style

We have seen Twitterbots that slice and dice, or recompose, the tweets of others, such as @twoheadlines and @pentametron. We have seen bots that react to the presence of certain trigger words or phrases in the tweets of others, as shown by @StealthMountain’s scorn for “sneak peaks.” And we have seen bots that splice together the tweets of others based on their use of a trigger word, as seen in @OliviaTaters’s fondness for “totally” and “literally.” In each case, the output of the Twitterbot is a function of the specific content of the tweets of others. Our proposed critic bot is very different in this regard: it does not react to, or reuse, the specific phrasing of another’s tweets but reacts to a broader analysis of that user’s social and linguistic footprint on Twitter. It is mediated in its reaction to other users by a third-party analysis that transcends single tweets to see the bigger picture that prevails across successive tweets. Yet in the end, it aims to compact this bigger picture back into a single, concise tweet. Our critic bot is modestly transformational in mapping a user to a broad-strokes picture of that user (via AnalyzeWords) before mapping this picture onto a tweet. The latter mapping is achieved using the simple game plan we have laid out. Taking the most extreme dimension from the AnalyzeWords.com profile of its target, which may be the dimension with the very lowest or very highest score, our critic bot chooses one of the canned responses that are defined for its quantized score. For example, a bot such as @onlinesarcasm whose Angry score approaches 100 will earn the scold, “So have you considered taking anger management classes?” or one of the alternates defined for Angry, Very High.10 If space in the tweet permits, an extra scold deriving from the second most extreme dimension can also be inserted. So @onlinesarcasm, which retweets what it believes to be the sarcastic tweets of others, might receive the following 135-character roast from our critic:

.@onlinesarcasm So have you considered taking anger management classes? You’re not very inward looking, are you? Not much to see I guess

The roast is delivered by retweeting the triggering message from the target, and not as a direct message, hence the “.” in front of the target handle. This reduces the likelihood that the response will be seen as unsolicited abuse, even when the target is a bot or a human who has invited judgment with the hashtag #JudgeMe.

If bots do not actively invite our critic’s scorn, how should they be targeted? We can use an indexing technique inspired by the stock market: when mutual funds set about investing in a certain diversified area of investment, they often track a major index such as the Dow or the NASDAQ; (the former comprises large blue-chip stocks, and the latter is skewed toward the technology sector). As stocks are listed or delisted from these indexes, a tracking fund will buy or sell its holdings accordingly. For our purposes, good listings of current bot “stocks” are offered by accounts such as Tully Hansen’s @botALLY and Jonathan Brodsky’s @BestOfTheBots. The latter is itself a bot that employs algorithmic curation to act as a sampler plate for diverse bots. Darius Kazemi describes @BestOfTheBots as suitable “for those of you who like bots in moderation, but don't want to follow a zillion of them.” Our critic can hurl its repackaged AnalyzeWords critiques at any bot whose output is retweeted by @BestOfTheBots by retweeting the curator’s retweet. It can use @BestOfTheBots as a dynamic index of which bots are actively tweeting and align its outputs to the timeline of a popular hub for bot outputs.

For instance, @BestOfTheBots retweets @RealHumanPraise, a Rob Dubbin bot that reframes snippets of positive movie reviews from RottenTomatoes.com as reviews of Fox News shows and their presenters.11 Given that the praise is both real and effusive, it is not surprising that AnalyzeWords scores Dubbin’s bot very highly on the Upbeat dimension (scores of 95–100 are common). But the bot also scores highly for Arrogance/Distance, which is perhaps not surprising given the nature of real human critics and the height from which they cast their reviews. Our critic bot might thus hurl the following critique back at @RealHumanPraise:

.@RealHumanPraise Upbeat?? You’re like the Energizer bunny after 10 espressos! Hey! Climb down off your throne once in a while your majesty!

We want our bot to be a critic, not a bully. It thus needs a memory of whom it has targeted and what it has tweeted in the recent past so that it does not repeatedly say the same things about the same bot targets. When the facts change, our bot should also change its tack by offering a different critique or, more trenchantly, reflecting on the perceived change in a target’s online personality. For the latter behavior, we need to feed a different roll of punched lines into our player piano. Let’s simplify the task with some convenient assumptions: assume our bot saves to its memory the time-stamped profile of each of its targets; assume our bot can compare and contrast the current profile, hot from AnalyzeWords.com, to the most recently critiqued profile; and assume our bot is responsive to changes of one or more quanta, either up or down, in any dimension. For instance, a change from High to Average to Low represents a downward shift of two quanta. We consider just four kinds of change: Lower, by one quantum; Much Lower, by two or more quanta; Higher, by one quantum; and Much Higher, by two or more. For these four contingencies, we arm our critic with one or more pointed questions:

Emotional Style

Social Style

Thinking Style

Let’s suppose @OliviaTaters dials down the anger a couple of notches, from Very High (81 percent) to a current score of 55 percent. Our critic might then respond to this Much Lower anger rating with the following tweet:

.@OliviaTaters Wow! Have you been lobotomized? You seem much less angry now.

Our critic may preface big changes with a “Wow!” or even an “OMG!” if the target scores high on the Spacy dimension. Modest changes earn a more sedate “huh?” While “less” signals the direction of the shift on the Angry dimension, the “much” underscores the extent of the shift. But if it seems that by giving our critic a sense of change we are building not just a cyberbully but a trash-talking stalker, it is worth noting that our critic’s principal opt-out targets are bots. Humans must opt in. Even so, we can allow a potential target to opt out by tweeting #DontJudgeMe. Just think of our critic as a layer of optional snark through which a bot fancier can view the curated outputs of bot hubs such as @botALLY and @BestOfTheBots. Different critics may exhibit varying levels of originality, irony, and wit, so that in a marketplace of bots, followers can choose the critic that best speaks to them, perhaps even using AnalyzeWords.com to explore the personality of each. In fact, in a world where bots become critics of others, our critic bots become subject to the very same kinds of criticism that they level at others.

Honey Roasted

If a spoonful of sugar makes the medicine go down, a fistful of emoji can encase our bot’s criticisms in an easy-to-swallow coating of cutesy charm.12 Emoji offer a baroque reimagining of ASCII emoticons, though they are not yet so numerous (at about eighteen hundred base images) that they overcome the most obvious objections to ideographic writing systems. As their name suggests, emoji are ideal for talking about our emotions, so it should be a simple matter to assign a distinct emoji to each of the quanta of the dimensions profiled by AnalyzeWords. So let’s try, this time assigning an emoji icon to even the average settings of each dimension:

10859_006_fig_007.jpg

10859_006_fig_008.jpg

10859_006_fig_009.jpg

10859_006_fig_010.jpg

10859_006_fig_011.jpg

Some dimensions are more amenable to visual depiction with emoji than others. For the AnalyzeWords dimensions that correspond to the basic human emotions (joy, anger, anxiety), we find a wealth of options in the Unicode standard, but for dimensions that are as hard to define as they are to name (e.g., Plugged-In), we are left with slim pickings. As we find ourselves scrambling for possibilities by the time we reach the Sensory and Plugged-In dimensions, we stop there and consider the nine dimensions already given to be sufficient for our purposes. In fact, as we’ll see, nine turns out to be especially well suited to our bot’s framing strategy.

As before, we can select the highest-scoring dimension in a profile to bear the brunt of our critic’s scorn. For the @OliviaTaters profile in our previous screen grab, this dimension is In-the-Moment, with a Very High score of 87. Our bot may thus choose to associate Olivia at this time with Unicode 1F61C, which depicts an irreverent soul who is playfully alive to the possibilities of the moment. Her second highest dimension is Angry with a Very High score of 81, for which the designated Unicode is the red-faced 1F621. Her third highest is Analytic at 79, which is merely High, earning her the dorky Unicode 1F913. The fourth highest is Arrogant/Distant at 74, also High, earning her a coldly skeptical 1F612. Rather than choose from these possibilities, a tweet contains enough room for all four, and so our bot can choose to arrange them in the 2 × 2 pattern made famous by Andy Warhol’s multicolored portraits of twentieth-century icons:

10859_006_fig_012.jpg

It’s not Marilyn Monroe or Chairman Mao, yet it has a low-res charm all its own. But, of course, there really is little reason to choose just four dimensions, since a tweet has room enough for all nine dimensions, arrayed in a convenient 3 × 3 grid:

10859_006_fig_013.jpg

This 3 × 3 arrangement has the added benefit that each dimension can occupy a fixed position in the grid, as each can now be depicted in every snapshot. When each position is associated with a specific dimension, it becomes easier for the viewer to compare and contrast two different emoji portraits of the same profile. For instance, our critic can dredge from its memory earlier states of the profile to depict the emotional progression of its target over time. If this is perhaps more reminiscent of Hogarth’s A Rake’s Progress than Wilde’s The Picture of Dorian Gray, both offer similar metaphorical takes on the same theme of moral change. So let’s imagine the progress of @realDonaldTrump in three profile snapshots, including the two shown previously and a third sampled two weeks later (after a period of monumental gaffes in public speeches and in social media):

10859_006_fig_014.jpg

A series of three 3 × 3 snapshots, aligned with a leading left space, arrow emoji between successive grids, and a new line between successive lines, requires 40 characters, leaving 100 characters for the text of the tweet. If space permits, we can also append the tag #FiftyShadesOfDorianGray (24 characters plus newline); otherwise we can assume the words “portrait” and “attic” are sufficient to prime the reader’s memory of Wilde’s Dorian Gray. Alternately, as our critic depends so crucially on the good offices of the AnalyzeWords web service, it seems only fair that each tweet include a URL to its website and the latest profile of its target.

Framing a profile as a Warhol silkscreen suits our mapping of personalities to faces, but we can opt for other kinds of framing by expanding our emoji base. For a full-body standing portrait, we can take inspiration from Matthew Rothenberg’s @EmojiDoll, which shows that there are more than enough emoji to depict not just the face of a cute cut-up character but the headwear, hands, body, and footwear too. 13 We can think of @EmojiDoll as the surrealist game exquisite corpse reinvented for the digital age, but a more apt and fun comparison is to those cutup flipbooks that delight children, in which they can flip an astronaut’s head onto a knight’s body on top of a ballerina’s legs, complete with a fluffy tutu.

10859_006_fig_015.jpg

When invoked with a beckoning “@emojidoll me” tweet, Rothenberg’s bot goes full Frankenstein (doctor, not monster) on the sender, responding with a fun but more or less random configuration of emojified hat, head, torso, hands (or hand contents) and footwear, of the kinds exhibited in the lineup above. Rothenberg’s bot became so popular that it quickly encountered problems with the default rate limitations imposed by the Twitter API. Although the ceiling was successfully raised, the bot hasn’t tweeted since July 2014.

It would not take much to make Rothenberg’s bot responsive to the personality of its targets. We could, for instance, imagine emoji dolls as voodoo dolls that are supposed to represent their targets, though instead of using a stolen lock of hair or a scrap of clothing, the new bot could build its dolls from their online traits. As an obvious starting point, the random face emoji that forms the doll’s head could be replaced with the emoji assigned to the target’s highest-scoring dimension on AnalyzeWords. A Very Angry target would thus receive a red-faced mask of rage, and a Highly Analytical target might be crowned with a robot’s noggin. But it would be a simple matter to also extend this mapping into the realm of hands, hats, and clothing to represent other dimensions with other parts of the doll. For instance, the following assortment of hands conveys a range of obvious outlooks:

10859_006_fig_016.jpg

Reading from left to right, we see hands denoting someone who scores Very Low on the Personable dimension, High and Very High on the Angry dimension, High and Very High on the Upbeat dimension, High on the Plugged In dimension and Very High on the Analytic dimension. Consider also these useful over-head emoji:

10859_006_fig_017.jpg

These can denote, respectively, someone who is High and Very High on Arrogant, Very Low on the Spacy dimension, someone who is High on Angry, someone who scores Low and someone who scores Very High on the Plugged In dimension, and someone who is Very High on the Personable dimension. Evoking the pathetic fallacy, we can also call on the weather (again from overhead) to denote varying levels of Depression or Worry, or perhaps low scores on the Upbeat dimension.

10859_006_fig_018.jpg

Replacing hands with their contents, the bot could use the following emoji to convey a Very High score on the Upbeat dimension (via the doll’s right hand), the Plugged In dimension (right again), the Analytic dimension (two for the left hand, one for the right), and the Angry dimension (one each for the left and the right hands):

10859_006_fig_019.jpg

In short there is a wealth of emojis to choose from if a bot were to fabricate a truly personalized doll to reflect its target’s current social profile. However, the mapping from profile to emoji is no longer a deterministic one: though a bot can put an apt face to most quanta of most dimensions, some quanta of some dimensions can also be visualized by specific choices of right or left hand, or of hand content, for example, and this choice—wider for some dimensions and quanta than others—presents a search problem. We can assume that a doll conveying N + 1 aspects of a target’s personality is preferable to one that conveys just N, even if one of the N + 1 is redundantly echoed in two different ways in two different locations. If we want the bot to squeeze as much of a target’s profile into each doll as possible, it will need to search the space of possible mappings of quanta to doll parts so that the end product is as fully loaded with personal meaning as possible. But once this search yields an optimal mapping of personal qualities to parts, it remains a simple matter for the bot to juxtapose dolls from successive snapshots of the same target in a Dorian Gray lineup. In any case, if you do build a bot like this that riffs on an earlier creation by another bot builder, as is the proposal here for riffing on Rothenberg’s @EmojiDoll, it is always good form to reference the earlier bot and its creator in your new bot’s Twitter bio.

Get Sorty

Oscar Wilde leaves us in no doubt that while Gray dresses well for the part, beneath all of his finery, Dorian remains thoroughly ungentlemanly. One could find this out by peeking at his decaying portrait in the attic, but popular fiction offers another possibility: If Dorian existed in the same world as Harry Potter and even attended the same school for budding wizards, which Hogwarts house would Dorian be asked to join?14 Not Gryffindor, whose members are known for their courage, bravery, and determination, or Hufflepuff, whose members value loyalty, patience, and hard work; or even Ravenclaw, for whose members, wit, learning, and wisdom are paramount. No, Slytherin is the only choice, for this is a house of pureblood snobs who prize cunning, pride, and ambition above all else. Harry’s creator, J. K. Rowling, imagines a magical sorting hat that reads the mind and soul of each new student so as to sort each into the most appropriate house. The Sorting Hat would quickly perceive Dorian’s true character and put him in this darkest and most disreputable of houses with a jaunty explanatory rhyme.15 Because others deserve the same bespoke service, the prolific bot builder Darius Kazemi has given the world the Sorting Hat Bot (@SortingBot), which assigns its followers to one of Hogwarts’ renowned houses with a novel verse.16 Kazemi deconstructed the rhymes of the Harry Potter books to build a generative mechanism that can invent new verses on the fly—for example:

@trumpscuttlebot Your mouth is main, your lip humane, yet you are so decayed. From this cathartic recipe, a Hufflepuff is made!

@SortingBot crafts each of its verse tweets from the magical idiom that readers associate with Harry’s world—note the frequent allusions to animals and their traits—and is careful to ensure that the end result both rhymes and scans. While the bot’s generative reach is broad enough to serve up a different verse for each follower, these servings are not tailored to the online personality of the recipient. Though “Your mouth is main” is a delightfully on-topic remark for a satirical Trump bot, the remark remains a random shot in the dark, like a fun horoscope from a carnival fortune-telling machine. Many Twitterbots explore the potential for randomness to stir special meaning and relevance for their human readers, and @SortingBot conducts its explorations with great charm and wit. Yet this charm is not diminished—indeed, its wit may well be sharpened—when a bot uses services such as AnalyzeWords to quantify the degree to which a recipient deserves to be described with specific labels. @SortingBot is a perfect Twitterbot whose many followers love it just the way it is, and Kazemi has good reasons for not wanting to make the bot more personal, chief among them being (we can imagine) a desire to not hurt the feelings of others. Nonetheless, it is interesting to contemplate how we might make a Twitterbot in the vein of @SortingBot more targeted and much more personal, at least for users who opt in. We could, for instance, use this know-how in the design of a bot that answers this popular exercise prompt for students of creative writing: “If you were a book, in which section of a bookshop would you be found?” Sorting followers into shelf categories such as True Crime, Humor, Politics, New Age, Ancient History, and Bargain requires much the same kind of classification ability as Rowling’s magical hat and affords a bot many of the same possibilities for humor.

We can consider the adjective remote to name a first-order property since a bot can determine its suitability by going directly to the AnalyzeWords dimension Arrogant/Remote. In all, depending on how easily we can name the extreme ends of each of its eleven dimensions, AnalyzeWords gives us approximately twenty first-order properties (such as Upbeat and Downbeat) and a variety of near-synonyms. But to determine whether a target user is a better fit for house Slytherin than it is for house Gryffindor, a bot will need to estimate the second-order properties Proud, Ambitious, and Cunning, as well as Fearless, Brave, and Determined. We call these properties second-order because they are not given directly by an AnalyzeWords profile, yet they can be estimated as a function of the properties that are given. If, for instance, we view cunning as an ability to analyze any situation to our benefit, we can define the second-order dimension Cunning as the product of the first-order dimensions Analytic and In-the-Moment. That is, a bot can estimate the extent to which a target is Cunning by multiplying together its scores for Analytic and In-the-Moment (if each dimension is normalized so that it runs from 0 to 1.0 rather than 0 to 100). Likewise, if we view pride as a form of upbeat narcissism, that is, a tendency to describe one’s own feelings and achievements in a positive light, we can define the second-order dimension Proud as the product of the first-order dimensions Upbeat and Sensory. And if we view ambition as a desire to lift oneself above one’s peers, that is, as a functional mixture of arrogance and optimism, we can estimate the second-order dimension Ambitious as the product of the first-order dimension Arrogant/Remote and the complement of the first-order dimension Worried (the opposite of Worried is (1 − Worried)). Though you might have gone a different way in defining these second-order properties, we are free to define as many formulas for the same property as we wish, provided that the value for any property in context is always given by its highest-scoring formula. We can also quantize the value of these second-order properties along the same lines as first-order ones, into Very Low, Low, Average, High, and Very High.

To be sorted into Slytherin, we should expect a target to score High or Very High for Proud, Ambitious, or Cunning, and so, in a contest between Gryffindor and Slytherin, our target should score High on more of the defining qualities of one house than the other if the sort is to seem fair. For simplicity, then, we assign a house one point for each of its defining qualities on which a target scores High and two points for each quality on which he or she scores Very High. If we have multiple definitions of a quality, we score this quality several times when a target scores High or Very High on several definitions. For example, if we have two functional definitions of Proud (the one already given and another that merely reuses the value of the dimension Arrogant/Remote) and a target scores High on one and Very High on the other, then that target will score 3 points for pride. This boost is warranted as it reflects the bot’s increased confidence in the label Proud. The sorting bot can now choose an apt house for a target user and justify its decision on the basis of first- and second-order properties of the user. But this bot will still have only twenty to thirty qualities it can use in its rhymes if we want those rhymes to also be explanatory. To allow the framing of a category judgment to be just as grounded as the judgment itself and to be just as expressive as we would want it to be, we must greatly expand our lexicon of second-order properties. To go beyond a small number of student houses or bookshop sections or whatever other categories are of interest to our bot, to consider a broader range of categories—as we will need to do if we want a bot to generate apt metaphors for a target based only on its AnalyzeWords profile—we shall need as large a lexicon as we can muster. Armed with this large lexicon of functionally grounded properties, an apt verse generator becomes licensed to use any quality for which the verse’s target scores High or a Very High.

To maximize reuse potential, we take an existing lexicon and give a functional definition (in terms of first-order AnalyzeWords dimensions) to terms that convey aspects of one’s personality. Our NOC list offers a good foundation for this new resource, as its two thousand or so properties are used to sketch sharply drawn personalities for a broad swathe of characters. We order the NOC’s properties by frequency, from most to least frequently used, and then work our way down this list to ensure that we concentrate our efforts on the most widely reusable terms. For instance, as eighty-nine NOC characters are described as witty we earn a large return on investment when we define this property as Upbeat × Personable. For a user who scores High on the Personable and Upbeat dimensions—high enough for the product of these two scores to also be considered High—now has at least eighty-nine candidates for figurative comparison in the NOC list. In contrast, rabble-rousing is used in the description of just one NOC character, and so we gain very little by defining this second-order property as Angry × Upbeat. In all we give functional definitions to over five hundred NOC properties, and as with the NOC itself, readers can download the fruit of this labor via BestOfBotWorlds.com. These five hundred properties put us in a solid position to generalize the metaphorical “sorting” of people by personality into an open-ended range of categories and creative perspectives.

The Universal Sorting Hat

It’s no exaggeration to say that metaphor is the universal sorting hat, a mental sorting mechanism that allows us to map life’s diversity onto an equally diverse set of named categories. Rowling’s sorting hat is a specialized kind of metaphor generator, as borne out by the categorical leaps of insight that her hat makes—for example, it recognizes the essence of a Gryffindor student in Hermione and Harry—and by the poetry of its justifications. But a bot with a wider vision that could generate real metaphors for real people would truly be a sorting hat for the real world. This metaphorical bot might rouse itself whenever a user opts in by tweeting the tag #LikeMe, to find an apt figurative counterpart for this user in the NOC. Though our bot must consider over eight hundred candidate counterparts (and more as the NOC grows), we can use much the same personality-matching process that maps users to Hogwarts houses. Given a set of first-order properties from a user’s profile, the bot can estimate every functional second-order property and quantize its score into the standard Very Low to Very High buckets. It can then filter those properties for which the user fails to score a High or Very High and compile a list of every NOC character whose entry contains at least one of the high-scoring properties. The bot can then tally a fitness score for each candidate as before, with a character earning one point for each property that is estimated as High for the user and two points for each that is estimated to be Very High. For example, a witty character on the candidate list earns one point when the user has a High (yet not Very High) value for Upbeat × Personable, and two points when its value is Very High. So the more properties that a user seems to share with a candidate character, the greater is the candidate’s overall fitness. The bot finally sorts its list of candidates by descriptive fitness, to form a ranking from most to least similar. To add a little chance to the mix and ensure that the bot does not always choose the same metaphor for the same profile, we may gently perturb the bot’s ranking by adding a small, random component to the fitness score of each candidate.

Few will be surprised to hear that Donald Trump tops the poll of candidates for @realDonaldTrump, yet he proves to be a surprisingly competitive candidate for the teen-spirited @OliviaTaters too. Surprises are fun, but our metaphor bot will need to explain its reasoning so that the best surprises are not dismissed as the products of random selection. Whichever framing device is used by our bot—and it may use a variety of devices, from the pointed to the poetic—it needs to tether its speculative flights of fancy to observable user behaviors on Twitter. In the following tweets, the bot reuses a rhetorical trick from an earlier chapter to set out its case in the form of a “tricolon,” a passing of the baton in three stages:

.@OliviaTaters Your tweets are so arrogant, self-regarding and egotistical that your painting in the attic must resemble Donald Trump.

.@OliviaTaters Wow, you must’ve been hacked by Donald Trump! Your tweets are just as arrogant, self-regarding and egotistical.

Note how the dimension “sensory” is glossed as “self-regarding” for a more pointed effect. It pays to lead with the first-order properties on which the subsequent second-order traits depend, and a tricolon allows the bot to put its best foot—or its most assured evidence from AnalyzeWords—forward, giving it a momentum that carries into its more tenuous speculation on the egotism of its target. Tricola can also be framed so as to integrate local color from the NOC, as in the following trash-talking tweets (the second-order sarcastic is defined as Angry × Arrogant):

.@OliviaTaters Your tweets are so arrogant, angry, and sarcastic you couldn’t be more like Donald Trump if you wore a meringue-shaped wig.

.@OliviaTaters Your tweets are arrogant, angry, and sarcastic. Did Donald Trump also teach you all he knows about developing real estate?

.@OliviaTaters If I said you’re as arrogant, angry, and sarcastic as Donald Trump would you crush me with your overweening self-belief?

A bot can also achieve greater variety by folding two metaphors into one tweet:

.@OliviaTaters Your tweets are so arrogant and angry. Would you say you’re as sarcastic as Donald Trump or more like Dr. Greg House?

This latter example uses a rhetorical question to slide a second-order property into the record. While the bot does not go so far as to call its target sarcastic, it does limit the user’s options to two NOC personalities that exemplify this quality. Recall that we can use the NOC to generate three-way comparisons that describe one character as a blend of two others, as in this tweet from @MetaphorMagnet:

#JohnLennon combines the best of #PabloPicasso and the worst of #JonStewart: witty and brilliant yet also acerbic, sarcastic and opinionated

While these threesomes exploit detailed knowledge about their targets, they can also seem sterile and airless, confined as they are to the carefully constructed toy box of the NOC that offers no view at all of the messy world outside. But a topical metaphor that addresses its target directly can punch right through the fourth wall to let a gust of much needed fresh air into a comparison, as in the following:

.@realDonaldTrump adds the best of #OsamaBinLaden to the worst of #ScottEvil: strategic and tactical yet moody, whiny and temperamental

One shouldn’t look for fairness in humor or in humorous metaphors. Indeed, as memorably “graphed” in a faux-scientific cartoon from Robert Mankoff in the New Yorker magazine, fairness and humor are inversely proportional measures.17 In the comparison above, even the source of positive talking points turns out to be the preeminent villain of modern times, while the source of negative qualities is not just negative overall, but pathetically negative. Metaphors always say more than they say on the surface, and what may seem like a shallow reflecting pool often turns out to be a wishing well in which readers see what they want to see. The ancient Greeks saw rhetoric as a practical art and set about defining a set of practical tools with which speakers could bend words to their meanings and, if so desired, bend these meanings to their pragmatic goals as a lens bends light. These tools were characterized and cataloged in loving detail to arm speakers with algorithms for meaning making, so it is no accident that this pseudo-code of persuasion now turns out to be so very well suited to Twitterbot construction.

Play D’OH!

The 2016 conference of the Cognitive Science Society was held in Philadelphia just a week after the Democratic National Convention crowned its presidential nominee in 2016.18 The streets around the convention center buzzed with residual energy, and outside, at a nearby church, fiery street preachers still waved placards that read, “Ask Me Why You’re Going to Hell.” The notices of this dignified old church told of a more temperate character and advertised a sermon with the eye-catching title, “Jesus Disrupts.” Metaphor is so pervasive that it often goes unnoticed by speaker and listener alike, but this was metaphor reveling in its status as metaphor. Its author wanted to do more than convey the power of religion to change lives, and so the metaphor deliberately and self-consciously appropriated the language of technology to foster the creation of new mental connections between the target domain of faith and the source domain of radical innovation. More than that, the metaphor subverted the modern view of disruptive pioneers—as best illustrated by Steve Jobs and his reality distortion field—as messiahs. If tech pioneers are to be revered as “messiahs,” then the metaphor urges us to have as much faith in the real deal as in the techies who design our phones. The metaphor scholar Gerard Steen describes such metaphors as deliberate because they are designed to be noticed and calculated to make playthings of their source and target domains. As metaphors go, this one was not just deliberate but surprisingly self-descriptive.

Metaphor disrupts. It disrupts our conceptual category system the way a game of musical chairs disrupts a formal dinner party, licensing guests to ignore the host’s place settings in favor of whatever works best when the music stops. It is the ultimate appropriation device, allowing speakers to appropriate the language norms of one domain of experience and transplant them wholesale onto another. Wherever metaphor goes, disruption and appropriation are sure to follow, even when we fail to notice, as we so often do, the deep upheaval taking place beneath the beguiling calmness of the metaphor’s surface. In fact, the path from metaphor to disruption is so deeply furrowed that it has become a two-way street. Bots use disruption and appropriation to achieve metaphorical ends, because a ruptured text is most easily made whole again by inferring the presence of metaphor. When @twoheadlines splices the content of two news tweets into one, it has no insight into what it has done except that it has created a disruption of the news, a disruption that readers often find easiest to understand in metaphorical terms. The only way for us to make any sense of the mashed-up headline “Twitter Was Robbed at Gunpoint In Brazil” is to treat it as a metaphor—perhaps a corrupt government is levying unfair taxes or fines on the company? —even though the original headline (about the mugging of athletes at the Rio Olympics) was literal.

@OliviaTaters wrecks a similar disruption on the breathless language of others, so when she tweets, “a smile would definitely cover the Sahara desert,” we sense a teenage mind groping for a metaphor that is within her sights but beyond her grasp. When @wikisext, a sexting bot created by @thricedotted from an idea by @rumnogg, extracts innocent snatches of text from the self-help site wikiHow.com and reframes them as sex talk between consenting adults, it is wrenching text from one context to reuse it into another where readers are more alive to the possibility of euphemistic metaphor. What the “milk,” “pan,” and “haddock” actually mean in the tweet, “sext: you drain my poaching milk from the pan . . . i check my haddock,” is anyone’s guess, but that is the point: readers are encouraged to create their own metaphors with their own meanings. Bots create metaphors whenever they sow the disruption of texts or contexts, even when they do not themselves comprehend the metaphors that subsequently bloom in the minds of their readers.

Words may be the building blocks of language, and ideas the stuff of thought, but metaphor is the play dough of the imagination. We turn so often to metaphor in this book because a bot that can shape its own metaphors from its own knowledge, with meanings and implications that a bot can appreciate for itself, has the creative flexibility to mold its metaphors into other products of the imagination too, such as insults, paeans, poems, jokes, stories, and even pictures.

In the next chapter, we explore how our bots can spin complex visual images around metaphors that are rooted in the personalities and AnalyzeWords profiles of their target users, and in the chapter after that, we explore the potential of our bots to spin yarns of threaded tweets from their own whimsical what-ifs. Yet whether our bots draw pictures or write plots, we show how knowledge-based metaphor generation allows them to satisfy a reader’s yearning for the novel and the familiar by throwing familiar faces into humorously incongruous settings.

Trace Elements

Tracery does not support the kind of features we would need for our grammars to analyze the personalities evident in the tweets of others, but we can still build playful grammars that speculate wildly about those personalities. A directory in our TraceElements repository named Personality Questionnaire contains a Tracery grammar of the same name (personality questionnaire.txt) that asks users to rate their own personal qualities on a scale from 0 to 10. It uses the collected qualities of the NOC list as its personality inventory, and uses the famous figures from the list to anchor each end of the scale. Here is a typical output from the grammar:

How AFFABLE are you? Answer on a scale of 0 (most AGGRESSIVE) . . . 10 (most AFFABLE), where 0 is Steve Jobs and 10 is Ned Flanders.

The labels for the opposite end of each scale (e.g., aggressive and affable) are provided by a resource named antonyms.txt that you will find in the NOC data repository. The textual content between NOC fillers is determined by a series of nonterminals that are defined at the bottom of the grammar, so changing these will allow you to vary the temper of the generator. The grammar uses transparently meaningful labels for each of its nonterminals, allowing the bulk of its content to be cut and pasted into other bot grammars as you see fit.

A second personality-related Tracery grammar can be found in the Viral Personalities directory of our TraceElements repository. Bots often reflect the personalities of their creators, so with this grammar we set out to imagine how a computer virus might also bear the mark of its maker, or failing that, the personality of a famous namesake. A key challenge required us to build a mapping of the personal qualities of famous personages to the malicious behaviors of fictional viruses. You will find the products of our wicked imagination in the spreadsheet viral symptoms.xlsx. The grammar exploits this mapping as a bridge between the personal qualities of NOC entities to the behaviors of viruses invented by, or inspired by, those entities. The following tweet is typical of the grammar’s outputs:

The inspirational virus JE5U5.CHR15T hacks your iTunes account and uses your credit card to buy every Tony Robbins self-help audiobook.

You will find one additional file in this directory: a response grammar that allows CBDQ to respond to Twitter mentions with a tweet like the above if a given property (such as inspirational) is also mentioned.

Notes