How TextGame.ai Works — Inside the AI Game Master
Most online social deduction games rely on rigid automation or a human host to manage the action.TextGame.ai takes a different approach: an AI Game Master that understands the rules, reacts to player choices, and keeps every session feeling fresh. Here's how it actually works under the hood.

What Is an AI Game Master?
In tabletop games like Werewolf or Mafia, someone usually has to sit out and moderate: dealing roles, announcing phases, counting votes, and resolving actions. That person is the Game Master.
On TextGame.ai, a large-language-model–powered AI takes on that role entirely. It assigns every player a secret role at the start, manages day and night phases, narrates what happens between rounds, and enforces the rules — all in real time, through natural-language messages in the chat.
Because the AI understands the game's rules rather than following a static script, it can handle edge cases, adapt narration to what players actually do, and even fill empty seats with believable AI characters so games can start without waiting for a full lobby.
How a Game Session Works
Every game on TextGame.ai follows a consistent flow, whether you're playing Werewolf, Mafia, or a completely custom game.
1. Choose a Template
Browse the game library and pick a template — or create your own. Each template defines the roles, phases, and win conditions the AI will enforce.
2. The AI Sets Up the Game
Once you start a session, the AI reads the template, generates a unique opening narration, and secretly assigns roles to every player (and any AI characters filling empty seats).
3. Players Join
Share the invite link with friends. They join instantly in the browser — no download, no account required. If there aren't enough humans, the AI fills remaining spots automatically.
4. The AI Runs Phases
Day discussion, voting, night actions — the AI announces each phase, sets timers, collects player inputs, and narrates results. It tallies votes, resolves kills, and checks win conditions after every round.
5. The AI Adapts
If a player makes a surprising accusation or an unexpected alliance forms, the AI adjusts its narration. It references earlier events, highlights contradictions, and keeps the story coherent from start to finish.
The AI Characters
One of the most common problems in online social deduction is not having enough players. On TextGame.ai, AI characters solve that problem — and they're far more than placeholders.
Each AI character is generated with a unique name, personality, and strategic style. Some are aggressive accusers; others play quiet and gather information. They argue with each other, cast suspicion, defend themselves when accused, and vote independently based on what they've observed during the game.
Because they're powered by the same language model as the Game Master, they can hold natural conversations, bluff convincingly, and react to context — not just follow a decision tree. Learn more in our deep dive on how AI characters think.
Custom Game Creation
You don't have to pick from existing templates. On TextGame.ai, you can describe a new game in plain English — the roles, the phases, the win conditions — and the AI will build a fully playable game from your description.
Want a murder-mystery dinner party with five suspects and a detective? A space-station mutiny with two traitors? Just describe it. The AI parses your rules, creates the role assignments, and hosts the game exactly as you designed it. Read our guide to creating games with AI for tips on writing effective game descriptions.
What Makes It Different
vs. Automated Game Engines
Platforms like Wolvesville or the original Town of Salem use hard-coded game logic: fixed role interactions, canned announcement text, and no flexibility if something unexpected happens. The AI Game Master on TextGame.ai generates narration dynamically, handles ambiguous situations gracefully, and can run games the developers never explicitly programmed.
vs. Human Game Masters
A skilled human GM can improvise brilliantly — but they need to learn the rules, stay impartial, and sacrifice their own turn to moderate. The AI Game Master knows every rule instantly, never gets tired, and is always perfectly neutral. It also means you never need to convince a friend to sit out and host.
vs. AI Dungeon-Style Generators
Open-ended AI story generators are fun, but they lack structure. TextGame.ai's AI is constrained by actual game rules — it enforces win conditions, tracks hidden information, and maintains fairness. It's creative narration within a competitive framework.
Frequently Asked Questions
Does the AI know everyone's roles?
Yes — the AI Game Master has full information about every role, just like a human moderator would. It uses this to resolve night actions, check win conditions, and narrate accurately. Individual players only see their own role and public information.
Is the AI biased toward certain players?
No. The AI follows the game rules neutrally. It doesn't favor any player or role. AI characters make their own decisions based on observable game events, not insider knowledge.
Can the AI handle rule disputes?
Because the AI understands the game rules as written, it resolves ambiguous situations consistently. If a custom game has contradictory rules, the AI will interpret them as logically as possible and keep the game moving.
Is my game data private?
Game sessions are private to the players in the room. Chat logs are not shared publicly, and the AI does not use your game data to train models. See our privacy policy for details.
Try the AI Game Master
Pick a game, invite friends, and let the AI handle everything. No download, no sign-up required.
Browse All Games