Skip to content

docs: align documentation with the create-snapshots + bootstrap pipeline#46

Merged
paolino merged 6 commits into
mainfrom
docs/review-amaru-bootstrap
Jun 12, 2026
Merged

docs: align documentation with the create-snapshots + bootstrap pipeline#46
paolino merged 6 commits into
mainfrom
docs/review-amaru-bootstrap

Conversation

@paolino

@paolino paolino commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Documentation review against the current state of the code, conforming to the org docs standard.

What was inaccurate

The docs were last aligned at 223437b, before the producer migrated to upstream amaru create-snapshots + amaru bootstrap (187359f) and before db-analyser returned to the image / the nonces.json gate was dropped (dadfc9a). As a result:

  • README, docs/index.md, docs/architecture.md, docs/bootstrap-producer.md and docs/tutorial.md all described the retired pipeline (ledger-state-emitter -> amaru convert-ledger-state -> header-extractor get-header -> nonce tail rewrite -> amaru import-ledger-state/import-headers/import-nonces). The actual pipeline in scripts/bootstrap-producer.sh is: preflight via header-extractor -> targets.json/snapshots.json from the chain's own block list -> amaru create-snapshots -> era-history sidecars -> amaru bootstrap -> atomic mv -T commit.
  • Documented bundle layouts still listed nonces.json and headers/; both are baked into chain.<network>.db by amaru bootstrap now (the layout is ledger db + chain db + snapshots/<network>/ + era-history.json).
  • The tutorial's expected log lines (+ ledger-state-emitter @, + amaru import-ledger-state) do not exist in the script; rc=9 was described as "import commands failed" (it is amaru bootstrap), and rc=6 was missing from the failure table.
  • bootstrap-producer.md misdescribed the era-readiness predicate ("at least two Conway epochs") and three check descriptions (bootstrap-producer-synthesized, antithesis-short-epoch-samples, antithesis-short-epoch-golden) asserted convert/import behaviour that nix/checks.nix no longer contains.
  • The constitution's Principle II examples claimed db-analyser is not in the runtime image (it is, as the create-snapshots engine) and listed amaru's commands as convert/import/run. Amended per its own governance (1.3.0, both the file and its docs/ symlink are one file).
  • HANDOFF-T019b.md was a stale root-level handoff describing the retired pipeline as current; removed.

What changed

  • README rewritten in the standard section order (What is this / Architecture with a mermaid overview / Install / Quickstart / Usage / Documentation / Development / License), all commands taken from the justfile, flake apps, and workflows.
  • docs pages corrected as above; the producer pipeline and producer state-machine diagrams redrawn from scripts/bootstrap-producer.sh (including the exit-code registry and the read-only chain DB rc=7 path); the relay-runtime, node-release-boundary and CI-proof diagrams updated; relay state machine verified node-by-node against scripts/amaru-relay-bootstrap.sh and kept.
  • bootstrap-producer.md gained the env-knob table (AMARU_WAIT_DEADLINE_SECONDS etc.) and the exit-code table; antithesis.md env table extended with the deadline/bin variables the relay actually exports.
  • mkdocs nav regrouped (User manual / Architecture / Development), keeping all pages.
  • Agent layer added per the org standard: AGENTS.md at the root, skills/amaru-bootstrap-guide/SKILL.md (agentskills.io format), CLAUDE.md converted to a thin pointer with its portable content moved into AGENTS.md.
  • Placeholder angle brackets in one mermaid label entity-escaped: with securityLevel: "strict" in mermaid-init.js, raw <scratch-out> text in labels gets sanitized away as a tag.

Verification

  • Every command and flag checked against the source: scripts/.sh, justfile, nix/{apps,checks,bootstrap-producer-image}.nix, .github/workflows/, cabal.project, app/*/Main.hs.
  • Diagrams validated node-by-node and edge-by-edge against the scripts; mermaid blocks checked for balanced quotes/brackets and valid arrows.
  • nix develop github:paolino/dev-assets?dir=mkdocs -c mkdocs build --strict passes with no warnings.

Out of scope, noted for follow-up

  • site/ (50 files) is a stale committed mkdocs build (pre-dates the current nav; Pages deploys via gh-deploy, so it is dead weight) and tmp/smoke-out/ (100 files) is committed smoke-test output including binary chain-db chunks. Both left untouched here as non-docs deletions.
  • nix/checks.nix writes a METADATA.md into the short-epoch corpus stating "synthesized slots: 720" while db-synthesizer is invoked with -s 3000; not touched because it is generated by nix code.

@paolino paolino added the docs Documentation label Jun 12, 2026
@paolino paolino self-assigned this Jun 12, 2026
@paolino paolino merged commit eee7223 into main Jun 12, 2026
4 checks passed
@paolino paolino deleted the docs/review-amaru-bootstrap branch June 12, 2026 07:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant