Skip to content

Bardo 1.0.0

Choose a tag to compare

@armando-andre armando-andre released this 02 Dec 12:54
· 57 commits to main since this release

The first release. Bardo is a local, file-based referee and memory for an AI Game Master. The agent narrates; Bardo calls no AI.

Added

  • Campaign folders. bardo init creates a campaign: bardo.json, a Game Master guide for the agent (AGENTS.md and CLAUDE.md) and folders for characters, NPCs, places, things, rules, knowledge and sessions. bardo add adds a character, NPC, place or thing. Everything is plain Markdown you can read and edit.
  • Modules. A small core every campaign has, and fourteen modules switched on when the game needs them (world, calendar, combat, factions, players, items, economy, languages, exploration, oracle, encounters, downtime, puzzles, simulation). Session zero asks which, with what each is good for; bardo module on|off <id> changes them at any time, and a module switched off keeps its files. bardo.json is format 2; a campaign made before modules keeps everything it had and is upgraded by its first change.
  • A guide for the modules that are on. AGENTS.md covers the core and the modules that are on, and bardo guide --write writes it again, keeping your notes under ## Your notes.
  • Fair dice. bardo roll rolls dice (2d6+1, d20+STR, keep-highest and keep-lowest, success pools), reads named stats from the roller, and logs every roll with its reason. Re-rolls are flagged.
  • More dice. Exploding dice (3d6!), Fudge dice (4dF), rerolling low faces once (2d6r1), GM-only rolls no player view shows (roll --gm), and a natural face on a check that always gives its top or bottom band (--natural-top 20).
  • Rules with the player's approval. bardo rules drafts a named check with outcome bands. A check can be rolled only after the player approves the exact rule, and again if the rule changes.
  • Rule effects. A check may state what each outcome does (--effect "hit: target hp -1d8+STR", a condition for a while, a cost); Bardo rolls and applies it in the same step, and undo takes the whole exchange back. Situational modifiers only within the range the rule allows, each with its reason (roll --mod +2 --mod-reason "high ground"); opposed checks (--vs) with a tie rule; conditions that end by themselves (condition --for 10m, or 2r for rounds of a fight).
  • Tables and the oracle. bardo table keeps random tables in the campaign, checks that they cover their dice and rolls on them by range, by weight or on a d66, with dice and other tables inside an entry and every die logged; starter tables of Bardo's own to copy; GM-only tables. The oracle module answers a yes-or-no question at chosen odds (bardo oracle), with an "and", a "but" or a twist; asking again is flagged like a re-roll.
  • What each character knows. bardo record and bardo learn keep per-character knowledge. bardo scene --as <character> shows what one character knows.
  • Revealing a secret. bardo learn <who> "…" --secret <id>:<key> records that a character learned a secret value. Their view and the party's view then show it; it stays hidden while another entity keeps the same words secret (SECRET_STILL_HIDDEN), and is hidden again if the value changes, the claim is forgotten or the learn is undone.
  • Facts and things that change. bardo set sets, changes, unsets or reveals an entity's facts; whoever is there sees the change, and everyone else keeps believing what they last saw (--gm: nobody sees it). bardo give hands a thing over, puts it down or into a container, and splits a stack (--count; add --quantity makes one); witnesses learn it.
  • Session zero. A new campaign starts in setup: bardo setup gives the agent the next of twelve setup questions with its help, bardo setup answer records the player's answer (or --you-decide), bardo setup ask adds the agent's own, and bardo setup done finishes once every question is answered and a main quest is open. Until then the commands that play (checks and other rolls, record, learn, move, travel, time advance and schedule, quest deadlines, fight, counter changes) refuse SETUP_PENDING; character creation may roll plain dice for a player character and set its counters (=n) and conditions. The setup state comes from the event log, so editing or deleting the file never opens the gate. The answers stay in story/session-zero.md, and the limits head every scene. Campaigns made before it count as set up.
  • Safety. The limits are a list anyone may add to at any time (bardo limits add line|veil), shown first in every scene, brief and setup; bardo check warns when a written line uses a word of a line (LINE_CROSSED), a safety net, not a guarantee. bardo pause stops the game for anyone, without a reason: until bardo resume, nothing changes but undo and the limits (PAUSED).
  • Quests. bardo quest keeps what the story drives toward: one open main quest, side, secret and personal quests, ordered steps, clues tied to what characters know, deadlines scheduled on the world clock and outcomes. Scenes list the open quests the viewer knows; a secret quest stays hidden until bardo learn … --quest <id>; bardo check warns about a missing main quest, a quest with no next step, a stalled quest and a deadline about to pass.
  • Threads and clues. bardo thread keeps the open questions, promises and foreshadowing that are not quests, each closed with what came of it; bardo clue adds clues tied to what they point to, which the party sees once a character finds one (clue found). GM-only threads and clue links stay hidden.
  • Telling and doubt. bardo tell passes on what someone believes, true or not, to everyone there, and it reads just like the truth; bardo distrust doubts a claim or a teller. Only the GM's view says which beliefs are wrong.
  • Brief, search and play sessions. bardo brief is the agent's short start of a session (limits first, then where everyone is, the fight, the last recap, quests, threads and what happened; --long, --for, --gm). bardo search looks through what the view may see. bardo session start|draft|end numbers the play sessions; a recap that holds a secret, an unlearned name or the GM's words is refused (RECAP_LEAK).
  • People and factions. bardo profile keeps a person's personality, motive, goal, fear and voice (a faction's goal, resources and methods), the GM's alone. bardo bond keeps how someone feels about someone, hostile to devoted, with a note; whoever is there sees it change. The factions module adds factions (add faction), who belongs to which (faction join, --gm for a spy) and what each thinks of the party.
  • Progress clocks. bardo clock counts 2 to 12 segments toward something, for a quest, a faction or a thread; --every 1d makes it fill as time passes, and a GM clock stays out of every player view.
  • Characters that grow. bardo create makes a party character by the campaign's creation rule: Bardo rolls in the open or checks the point buy, and places rolls where the rule allows (--assign). bardo xp and bardo advance add experience and apply the next level by the advancement rule, which the agent writes in its own words.
  • Players, spotlight and handouts. The players module knows who plays which character (bardo player add), with names kept out of the story; bardo spotlight names who has had the least of the session; bardo handout gives one player a note their characters alone learn.
  • Names. bardo name --gm suggests names from the world pack's peoples, by place, status, family and parent, and never one the campaign already uses. The built-in packs come with peoples; bardo check warns when a people's status can never be named (PEOPLE_NAMES_NOTHING).
  • Secrets. Text under ## GM only, secret: facts, secret counters and stats, and the real names of NPCs shown under a description stay out of the player's view, in every command and in --json. --gm views show everything for the GM. Player output goes through one boundary that hides them.
  • Player views from what was perceived. Each event stores what every viewer perceived of it, and the player views are built from that; tests play twin campaigns that differ only in what the party never saw and check that every view and reply reads alike. docs/perception.md lists the rules and the accepted limits.
  • Time. A clock with an optional calendar, bardo time advance, and scheduled consequences that fire when the clock passes them.
  • Places and travel. bardo move and bardo travel move characters along exits and run the clock for each leg.
  • Exploration and maps. The exploration module adds hidden ways and secret places (exit --gm, bardo hide) that stay off every view until a character discovers them (bardo discover); travel slowed or sped by the kind of way (road, trail, river, ford, ferry) and the weather (bardo weather, weather set); bardo route to plan a journey; supplies spent each day on the road, with a warning when they run low; and bardo map of what the party knows, as text or an SVG picture (--svg).
  • Encounters. The encounters module rolls the encounter table that fits the terrain, the kind of place, the region, the time of day, the season and the weather (bardo encounter roll), and checks by chance on each leg of a journey and as time passes, for the GM alone. Two starter encounter tables.
  • Downtime. The downtime module spends days or weeks on an activity in one step (bardo downtime <who> <activity>): the clock runs, the activity's check is rolled each period, its cost paid and its results applied, and one undo takes it all back.
  • Puzzles. The puzzles module keeps riddles, locks and ciphers with their solution hidden from the players (bardo puzzle): hints in order, every attempt logged and compared without case, accents or punctuation, a GM solve for an answer right in spirit, and a quest step it can complete.
  • Long jumps and a bigger world. bardo time advance runs up to ten years in one event, or --until a date, firing everything due on the way in order; consequences can recur (time schedule --every, with --until or --count). Up to 10,000 characters, places and things, with an index in .bardo/ so commands stay quick.
  • Fights and numbers. A generic fight tracker (bardo fight), counters (bardo counter) and conditions (bardo condition). Bardo tracks the numbers; the approved rules decide what a hit does.
  • The combat module. bardo fight settings sets the combat rule, how long a round lasts on the clock and a defeat rule (such as hit points at 0) that takes a combatant out the moment it is met; fights have sides, say when only one is left standing, roll initiative (--initiative) and end with a tally of the checks rolled and the damage dealt and taken.
  • A generated world. bardo world seed fills a campaign's blanks with regions, settlements, routes, history and markets from a seed. bardo world pack use picks the words the world uses. bardo world routine gives NPCs a daily routine. bardo scene and bardo world show today's weather, festivals, prices and news.
  • Deep worlds. A seeded world has continents and seas, kingdoms with borders, seats and rulers, faiths with holy places and feast days on the calendar, peoples with homelands, moons and a dated history. bardo world npc makes a kingdom's ruler or a faith's clergy when the story needs one. A third built-in pack, starfaring, gives the same world in starfaring words (systems, stations, lanes and jumps).
  • A world that moves on its own. The simulation module runs a daily tick by Bardo's rules and seeded dice, inside the event that moves the clock: the GM's faction and kingdom clocks (--gm) gain and set rivals back, NPCs pursue their goals on personal clocks (clock add --npc --gm, --toward a place) and travel toward them, market stock and prices follow production, demand and trade, exchange rates drift, rumours spread along the ways, and notable results go into rules/world/chronicle.md. It is the GM's: a digest in the --gm-reply of passing time, bardo world log --gm, a preview with bardo tick --days n --dry-run --gm, and bardo overrule <id> --reason to take a result back. The party learns of it only in the world (a rumour, being there, being told), never out of band (docs/perception.md).
  • Languages. The languages module gives each people a language of its own words, the same every session (bardo lang renders a phrase, --words lists them), and knows who speaks what: speech in a tongue a character does not know reads as speech they could not follow (record --in, tell --in, scene --in).
  • Gear and items. Containers with a capacity; a closed one hides what is inside from all but whoever carries it. bardo equip and unequip wear or hold gear in a slot, a sheet shows what each character carries and wears and what it is worth as far as they know, and bardo thing shows a thing's history as the view saw it. The items module adds rarity, durability that wears down to broken, and items rolled from tables (bardo item roll).
  • Money and trade. The economy module adds the setting's currencies and coins from the world pack, a purse for each character (bardo purse), paying (bardo pay), and buying and selling at a market's prices (bardo buy, bardo sell, bardo market), which follow the season and the news; a foreign currency changes at its rate.
  • History and undo. bardo history shows what happened. bardo undo restores the files, clock, fight and schedule from before the latest event; its rolls stay in the log, marked void.
  • Checks and repair. bardo check reports problems in a campaign, --accept adopts hand edits, --fix repairs a torn last log line, and --gm shows real paths for repairs. It exits 2 when it finds errors.
  • Crash safety. A change is journaled, so the next command finishes one that a crash interrupted. One command at a time holds the campaign lock.
  • Machine output. Every command takes --json and returns one JSON object, with stable error codes and exit codes.
  • The bardo-gm agent skill, generated from the same source as the campaign guide.
  • A playtest harness (pnpm playtest) that plays Claude Code, Codex, OpenCode or a scripted player through a game inside a sandbox and checks the result: no leaked secrets, no invented rolls, approvals respected. It is not published.
  • Tests. Unit and property tests, mutation testing (pnpm mutate) and coverage (pnpm coverage).
  • Project docs and CI. README, CONTRIBUTING, SECURITY, this changelog, funding links, and a CI workflow for Linux, macOS and Windows on Node 22 and 24.
  • Releases from GitHub. Pushing a v<version> tag on main publishes @bardo-ttrpg/cli through npm trusted publishing, after the full check; no npm token is stored. CONTRIBUTING says how to release.
  • Design records. GLOSSARY.md and docs/adr/ hold the project's terms and decisions; docs/perception.md holds what each viewer perceives.
  • An example campaign. examples/the-salt-road, built by Bardo's own commands (pnpm gen:example): session zero done, a seeded world, a market, a faction with its clocks, an NPC with a profile, a first session and three days of the world moving on its own.

Security

  • A hostile campaign folder is treated as untrusted input. Bardo never runs anything it finds there.
  • A ## GM only heading is recognised even with invisible, lookalike or combining characters in it.
  • Usage and parse errors do not echo the text you typed, so they cannot show a hidden name or secret.
  • bardo check hides a hidden name that appears in a file path.
  • File reads are bounded and checked before they are read: size caps, no symbolic links out of the campaign, no hard-linked logs, no named pipes, and a 10,000-entity cap. The event and dice logs have a 256 MB ceiling.
  • Parsing takes time in proportion to the input: a very long line cannot hang a command.
  • A forged or hand-edited journal or undo image can write only the files Bardo itself manages, with content that reads back. It cannot write agent configuration such as .claude/settings.json, .mcp.json or CLAUDE.md.
  • A new id is never claude, agents, agent, gemini or qwen, whatever the case, because a coding agent loads a file of that name as instructions. A name like "Claude" gets the id claude-2 and is still shown as "Claude". Bardo refuses to write such a file (AGENT_FILE_NAME); a campaign that already holds one is still read, and bardo check warns and says to rename it.
  • Journal records must each be one line, so recovery cannot add forged lines to the logs.
  • A forged lock file cannot block the campaign or add lines to the output.
  • Event numbers have an upper bound.
  • Files that cannot be written safely are refused before anything is changed, so a command does not half-apply.