Web game
A quiz where your friends pick the topic and AI writes the questions.
A real-time multiplayer trivia game I built from scratch. Make a room, share the code, and take turns choosing what the next question is about.

- The problem
- Quiz games run out of questions, and nobody wants trivia about topics they didn't choose.
- What I built
- A live multiplayer room where any topic becomes a fresh question in seconds, scored on speed and streaks.
- The result
- Up to eight players a room, a question every round, and it keeps working when an AI provider says no.
How I built it
The problem
The fun part is the topic. Most quizzes take it away.
Trivia apps give you a fixed bank: general knowledge, a few categories, the same questions again by the third game. The best moment in a quiz night is someone saying "ask us about 90s cricket", and a fixed bank can't do that.
So in Qotion the players choose. Each round, the next person in the room types any topic, and the question is written for it on the spot.
What made it hard
Free AI is fast until it says no.
Live questions mean an AI call in the middle of a game, and free tiers rate-limit without warning. A game that freezes for eight people because one provider is busy is worse than no game.
Questions go through a chain of providers: Groq, then Cerebras, SambaNova and Gemini, then a smaller Groq model. If one refuses, the next one answers, and the players never see it. If every provider fails, a built-in pool of questions still keeps the round going.
One bug taught me to check the order of my own rules. The difficulty mix aims for about 35% easy and 20% hard questions, but the code checked hard first, so every single game opened on a hard question. Checking easy first fixed it.

What I built
A room that survives people leaving.
Multiplayer bugs come from people doing normal things at the wrong time: closing the tab mid-question, losing signal, joining late. Every one of those had to leave the game in a sane state.
Drops are not exits
A disconnect gives a player 15 seconds to come back before they are removed. The round keeps going either way.
The clock belongs to the game
Only the game can stop a question timer, so one player leaving can never cut a round short for everyone else.
No repeats across rooms
Questions are checked against recent ones by wording, by answer and by meaning, so the same fact doesn't come back in a different sentence.
Every question is checked
Answers that leak into the question, duplicate options and profanity are rejected before anyone sees them, and options are shuffled.
What is not done yet
It needs a home again.
Qotion ran at qotion.online. The server is offline right now, so these screenshots are from running it on my own machine.
- Getting it back online. It needs an always-on server for the live connections, so it can't sit on the same static hosting as the rest of this site.
- Making it pay for itself. AdSense turned it down for not looking like a content site, so the plan now is a paid tier for hosts and sponsored rooms rather than more ads.
- With no AI keys, the local build answers from the built-in pool, so the topic and the question don't always match. The live version writes each question for the topic.