Murder on the Train!



Four elite families. One prize dog pageant. One murder. Unfortunately you are the culprit! To get yourself out of this sticky situation, you must lie, persuade, bribe and derail direct communication as much as possible to win.

Intro to the game

Here are some of my favorite responses from users:


First Image:
Poirot (anger): “Oliver, your questions have led me to consider the possibility of Jameson’s involvement. Let’s not jump to conclusions just yet.”
Hastings (anger): “Oliver, your so-called questioning lacks credibility. I find it highly suspicious that you’re trying to deflect the attention away from yourself.”

Second Image:
Poirot (fear): “Oliver, we will ensure your safety. If you have any reason to believe you’re in danger, you must share it with us immediately.”
Hastings (anger): “Oliver, accusing Hastings of wanting to harm you won’t help your case. Focus on providing relevant information, not spreading baseless fears.”

Third Image:
Poirot (intrigue): “Please, Oliver, elaborate on what you heardand provide any other pertinent details.”
Hastings (humor): “Oh, Oliver. A broken plate does notnecessarily mean foul play. We must focus on the facts and evidence.”

Fourth Image:
Poirot (compassion): “I understand your concern for animal welfare. Can you provide any evidence to support your claim?”
Hastings (shocked): ”So you and my daughter were actively working together to fight animal abuse. I must say, I’m impressed.”


The project uses the OpenAI API and node.js to create character dialogue based on user input. When the user submits new information, The AI makes a guess on who is the suspect - which can include the user -, guesses how much favor the user's character has with the two interrogators, guesses each character's emotion and displays the proper facial expression, and displays what the interrogators would say in response based on their personalities.

User input varied from “I did the murder. What are you going to do about it?” to “I saw you do it I think.” to “Your prize dogs look like NYC sewer rats”. Some users spun out detailed alibis, and the AI adapted to accomodate the story.

To win, the user must get 5/5 favor points with at least one interrogator, and getting a 1/5 will result in a game over.


Created with node.js and the OpenAI API. Special thanks to Dror Malgarit for coding help! Visuals drawn with Adobe Photoshop