Inspired by Rob Dubbin, I made a new Twitter bot last week called Professor Jocular (@ProfJocular). It tries to explain jokes. Here’s how it works:
- grabs short tweets from Favstar’s Tweets of the Day (there’s no API for this so I just scrape it)
- picks a random short tweet
- gets three random words (of 4+ characters) from the tweet
- uses Wordnik to findĀ hypernyms for those words (a hypernym is an encompassing concept. for example, a hypernym of “dog” would be “animal”)
- then it picks a hypernym and says: “[theHypernym joke] RT @example This is the joke.”
I’m pretty happy with it. However, it got suspended automatically by Twitter yesterday. The reason it got banned is because it was @replying a lot of people who don’t follow it. To Twitter, that looks like spam (and reasonably so).
If you’re familiar with my article Basic Twitter Bot Etiquette, you might ask, “Why did you @reply when you know it’s against the rules?” Well, I originally didn’t want to tag people in the tweets, but Rob made the point that if I did that, the bot would be stealing jokes. I do want to attribute jokes to people, so I left the @’s in place.
But of course, Twitter suspended the bot. When I logged in I saw this message:
That was kind of cool to see: Twitter is saying, “If you promise to behave, we’ll unsuspend you immediately, but if you misbehave again, we’re banning you outright.” So I changed the bot to do “.reply” instead of “@reply”: this way I attribute the jokes, but there’s no actual notification stuff happening, so it’s not spam.
A funny thing
Probably the funniest thing to come out of this? Here’s the last tweet Professor Jocular made before it got banned:
[joke joke] RT @ChiefTwittler: You put "funny" in your bio? Is that the funny part??
— Professor Jocular (@ProfJocular) July 27, 2013
Joke joke. I love it. Now here’s the first thing it tweeted after being unsuspended:
[death joke] RT .IanKinney: I'll treat you like a gentleman, but that doesn't mean I'm going to be gentle.
— Professor Jocular (@ProfJocular) July 28, 2013
DEATH joke?! My goodness, little bot, you have a dark sense of humor.
Comments on this entry are closed.