A classroom experiment in Twitter Bots and creativity

Author

Matt Waite

Published

November 20, 2014

This semester, I’m teaching a class in Story Bots, which is really a programming class disguised as a journalism class. I’m teaching students enough programming that they can automate journalistically useful things, things like scrape a website and alert you to a potential story. Or take a dataset and turn each record into a journalistic narrative. 

One of the assignments was to make a Twitter bot. They could do what they wanted with it, but it had to use Twitter and had to run on a simple cron job. It had to tweet, and they had to put their bot on Github when they were done (sans access keys). 

Here’s what they came up with.

Lady Plath by Sara Janak

Lady Plath takes a line from a Sylvia Plath poem and a line of Lady Gaga lyrics and randomly combines them into gloriously weird tweets. Example:

Code here.

Nebraska UFOs by Jeff Renken

This bot goes to the National UFO Reporting Center and checks for new reports in Nebraska. If it finds one, it tweets it out. Example:

Code here.

Random Homer Simpson Quote bot by Jordan Tate

A select few people who hashtag something #HomerSimpson will get a randomly chosen quote response from the Random Homer Simpson Quote bot. Does what it says on the tin.

Code here.

Tarantino ebooks by Tony Papousek

This bot does two things: uses Markov chains to write a new Tarantino script, 140 characters at a time, and responds to anyone who tweets “English motherf***er, do you speak it” with a simple “What?” (If you haven’t seen Pulp Fiction, shame on you). 

Code here.

Rebel_ebooks by Spencer Hansen

Excited for the new Star Wars movie? Read lines of dialogue before they appear on screen though the miracles of Markov chains of the Empire Strikes Back script (the best movie, FYI). 

Code here.

Matt Waite ebooks by Daniel Wheaton

I like to think I run my classes a little different from most other university courses and it’s conversations like this that give me hope it’s true:

Daniel: “Can I have your complete Twitter archive?”

Matt: “Uh, why?”

Daniel: “I don’t want to say.”

Matt: “Sure, why not.”

And then this happens.

Code here.

In the interests of shared suffering, I made my own. It’s pretty tame by comparison. 

LNK Lost Dog Bot by Matt Waite

The City of Lincoln has a Lost Pets page, where they put reports of lost animals. I scrape the dogs and tweet out the new ones with a number to call if you’ve seen them. Simple.

With all this grading to do, I haven’t put my code up.