Practice · The document suite

The Spec Argues Back

Fourteen numbered documents specify the design. The machinery between them does the governing: a convention for recording being wrong, a register that tracks corrections across documents and stable ids that tie code, docs and roadmap together.

The map

DocsRole
00–03Orientation: the index, a project audit snapshot, the six design pillars, the systems map. Doc 02 is where Simulation Honesty and Error Is the Engine live; most decisions on these pages trace to one of the six.
04–10Specifications, one system each: the interpretive lens, generation (doc 05, the one these pages lean on most), knowledge and contradiction, career and social systems, technical architecture, the implementation roadmap's phase logic, the document tradition system.
11–13Governance: locked decisions (11), the propagation register (12), post-MVP deferrals (13). Plus docs/spikes/ for standalone design-spike write-ups and docs/roadmaps/mvp.md, the task-level execution plan projected from .claude/roadmaps.json.
docs/
├── 00-project-overview.md            # index + reading orders
├── 02-design-pillars.md              # the six non-negotiables
├── 05-generation-architecture.md     # these pages' main source
├── 11-deferred-design-questions.md   # locked decisions
├── 12-propagation-register.md        # cross-document correction ledger
├── roadmaps/mvp.md                   # task-level plan (projection of roadmaps.json)
└── spikes/                           # one write-up per design spike, named by task id

What happens when the spec is wrong

Specs usually meet implementation in one of two ways: the spec quietly rots while the code moves on, or somebody rewrites it and the reasoning behind the first version disappears. This suite does a third thing. When implementation contradicts doc 05, the original text stays put, and a dated implementation note lands directly beneath it recording what shipped instead, why, and which task made the change.

A concrete run of it, from this year:

  1. Doc 05 §8.3 describes decoration recursion depth as a single table keyed on craft specialisation and decorative emphasis, with two middle corners reading "technically refined" and "simple techniques".
  2. Someone builds against it. The two middle corners turn out unsatisfiable by any single volume scalar: they differ by kind, not magnitude, which the table's own wording already says but a shared fill-probability term can't express.
  3. The table stays exactly as written. A note dated 2026-08-06 lands directly beneath it, explaining the volume/grade split that shipped instead and citing the task (2GN.98) that made the call.
  4. Anyone who learned the table finds the correction exactly where their memory points; anyone arriving fresh reads the shipped mechanism and the table it replaced in the same screenful.
Why keep the wrong text nearby The cost is a longer document. What it buys: the note names the evidence and the reasoning, so a future reader can re-litigate the decision; the spec doubles as a decision log without a separate ADR system to maintain; and a contradiction between doc and code is always one of two known states (note pending, or defect) rather than the usual third state of "who knows which is current". Not every correction works this way: doc 05 §8.2's "you don't gild wood" was a flat factual error (gilded wood over gesso is the commonest gilding in the historical record) with nothing to preserve, so that one was deleted outright and replaced by the correction alone. The decoration depth table is the harder case, kept nearby because the table's own reasoning stays worth reading even though its conclusion doesn't hold.

The register, the spikes, the ids

Three mechanisms keep fourteen documents from contradicting each other:

orientation00 index · 01 audit02 pillars · 03 map specifications04 lens · 05 generation06 knowledge · 07 career08 technical · 09 phases10 documents governance11 locked decisions12 propagation register13 deferrals · spikes/roadmaps.json → mvp.md rulings propagate back into the specs as dated notes
Orientation feeds specification; governance corrects it; the corrections land back inside the specs, dated.

Reading order, if you go to the source

Start with doc 02 (the six pillars), then doc 03 (the systems map), then doc 05 with these pages beside it; doc 00 carries reading orders for other purposes (implementing, reviewing, catching up on decisions). For code, src/lib/engine/prng.ts then src/lib/engine/generation/grammar.ts top to bottom. Start each module at its JSDoc block: the contracts live there, several run longer than the code beneath them, and the doc-12 cross-references inside them are load-bearing rather than decorative.

Where it lives Docs: docs/00–13 · Spikes: docs/spikes/ · Roadmap: docs/roadmaps/mvp.md (projection of .claude/roadmaps.json) · Agent guide: .claude/CLAUDE.md