Just Joking, but Seriously Bot

Shaun McAvinney
3 min readSep 5, 2015

--

So, I decided to make a twitter bot. Like most things I make, it exists because of a dumb joke that I decided to take too far.

August 17 was The Verge’s hack week, and one of the projects caught my eye. There was a single page app that would generate a caption for the New Yorkers comic caption contest. I thought the idea was really great, and the non-sequitur nature of a cartoon and a random line of text is my kind of humor.

A buddy at work and I started sending good matches back and forth and quickly realized that there was a limited well of captions that the app was rotating through.

After a bit more digging we confirmed our suspicions and found the csv that they were using to populate the app with. You can take a look at the captions by downloading it here.

That is when I decided to spend the next week of my spare time building @NotYorker. I really liked The Verge’s take on The New Yorker’s comics. They cited this Seinfeld Episode as a source of inspiration. Essentially, the joke is that no one understands the New Yorker comics, not even editors themselves. It was just disappointing that The Verge team didn’t actually generate new comics that had absolutely no context. I wanted something that made just as little sense as the New Yorker comics, while being just as funny. Now that would be hilarious.

ELAINE: (gets up) You know what? you people should be ashamed of yourself, you know ya doodle a couple of bears at a cocktail party talking about the stock market. You think you’re doing comedy.

MR. ELINOFF: Actually that’s not bad..

This wasn’t the first time I had decided to build a bot. About a year ago, a few of my colleagues had built twitter bots, some really amazing (@alonelyproject), others were just hilariously insane (@bengarvey_brain and @lauren_ipsum). I had decided to take the twitter bot absurdity to a new level, so I built @RapbotRapbot, a twitter bot that responded to rap lyrics with a very descriptive explanation of what that lyric means, in typical robot efficiency.

RapbotRapbot is down, due to a missing cord for my rapsberry pi :(

RapbotRapbot was an exercise in excess. I wanted to tie as many services together in one bot. The bot took messages from twitter, searched RapGenius for a matching annotation, turned to text into a robot mp3, uploaded that mp3 to soundcloud, and finally tweeted back with the soundcloud link. It was crazy, and didn’t work all of the time.

With NotYorker I wanted to take a different approach. For one, I wanted a bot that didn’t rely on as many third party services. Secondly, RapbotRapbot was built with ruby, and included some pretty squirrelly code to get it to run on a regular basis. There are a few different bot frameworks out there that would have gotten me half of the way, but I’ve recently started diving into Node.js and decided it would be good education to build it from scratch.

So after about a week of work, @NotYorker is alive and will generates an infinite number of new captions for New Yorker comics. The results are pretty good, most of the time. After about a dozen of these, I started marveling at how our brains will take something we know contextually _should be_ funny (but isn’t), and agree that it is funny.

Sometimes necessity isn’t the mother of invention, a dumb joke is.

--

--

Shaun McAvinney

Sales at Stitch. I also cobble stackoverflow answers into things sometimes.