Your agent, as Game Master
Play tabletop RPGs with the coding agent you already have.
Fair dice, agreed rules, kept secrets, a living world, easy undo, any game.
the-millbrook-bell
Read the transcriptBack to the video

Bardo works with the coding agent you already use.
- Claude Code
- Codex
- OpenCode
- Antigravity
- Copilot CLI
- Cursor
- Grok
- Pi
(02) — What is Bardo?
Bardo is a CLI, a command-line tool: a small program your coding agent runs for you, much as you would reach for a calculator. Coding agents can now do far more than write code, and with the right tools they can run a whole campaign. Bardo is that toolbox, made for tabletop RPGs, from the first scene to the hundredth.
Any game
Any tabletop RPG, by the rules you give it in your own words or draft from your rulebook.
Plain files
The campaign is Markdown in a folder on your computer.
Completely free
No ads, no account, no subscriptions, no nothing. Free, period.
No AI of its own
Your agent does the talking. Bardo keeps the facts: dice, rules, clock, secrets, and much more.
Features
Your agent brings the story. Bardo brings everything a long campaign needs to stay fair and remembered.
See every feature on GitHub →Session zero
Before the first scene your agent asks how you want to play: the game, the tone, your limits. Play waits until it’s done.
Fair dice
Bardo rolls every die, never the agent, and logs who rolled, why and every face. Re-rolls are flagged.
Secrets that stay secret
GM-only notes, hidden names, and what each character has learned. You see only what the party knows.
A living world
A world clock, travel, weather, festivals, market prices, and NPCs who keep daily routines.
Quests with deadlines
A main quest, side and secret quests with ordered steps, and threats that strike on time whether or not you arrive.
Fights
Turn order, sides and rounds, a defeat rule you choose, and a tally of the damage dealt and taken when it ends.
An oracle for solo play
Ask a yes-or-no question at the odds the story suggests, and get yes or no, sometimes with an “and” or a “but”.
Undo
Take back the latest move: its files, the clock and the fight. Its rolls stay in the log, so undo is never a free re-roll.
Install
Install it once. The command is bardo.
- pnpm
pnpm add -g @bardo-ttrpg/cli - npm
npm install -g @bardo-ttrpg/cli - bun
bun add -g @bardo-ttrpg/cli - try
pnpx @bardo-ttrpg/cli --help
Bardo needs Node.js 22 or newer and a coding agent that can run commands. Then make a campaign with bardo init the-millbrook-bell, open the folder with your agent, and ask it to be your Game Master.
Fully open source. The code is on GitHub under the MIT licence: read it, change it, share it, build on it.
Enjoying it? If Bardo earns a place at your table, you can support it on Buy Me A Coffee.
FAQ
What is Bardo?
A free command-line tool that turns your coding agent into a tabletop RPG Game Master. Your agent tells the story; Bardo rolls the dice, keeps the rules and the secrets, and remembers the world, in plain files on your computer.
How do I play?
Install Bardo, make a campaign with bardo init, and open the folder with your agent. Bardo writes a Game Master guide into the folder (AGENTS.md, the file most agents read) and ships the same guide as an agent skill, so your agent knows to use bardo for every roll, move and fact. Then tell it what you want to play.
Do I need an API key or an AI subscription?
Not for Bardo: it calls no AI of its own and needs no account. Your agent runs on the plan it already uses, or on a free model if your agent offers one.
Which coding agents work?
Bardo is tested with the first four agents shown above, and any coding agent that can run commands in a folder should work. Your agent needs your permission to run bardo.
Which games can I play?
Any tabletop RPG. Give Bardo the rules in your own words, or let your agent draft them from your rulebook; Bardo rolls a check only once you have approved its rule.
Can I play solo?
Yes. The oracle answers yes-or-no questions at the odds the story suggests, and random tables of encounters, rumours and loot fill in what nobody at the table knows.
Can the agent cheat?
Bardo rolls every die and logs who rolled, why and every face. A second roll for the same thing is flagged, and undone rolls stay in the log, marked void. Secrets stay out of your view, and Bardo warns when one slips into the story.
Where do my files go?
Nowhere. The campaign is a folder of Markdown files on your computer, and Bardo itself sends nothing anywhere. Your agent’s provider sees what the agent reads, as with any coding work.
How much does it cost, and is it open source?
Nothing: Bardo is free and open source under the MIT licence. Read the code, change it, share it. If it earns a place at your table, you can support it on Buy Me A Coffee.


