# Documentation Templates

One file per template. Every template is either a **truth document** (states current absolutes, updated in place) or a **record** (dated account of activity, frozen or append-only) — the split is defined in `SKILL.md` § The Two Natures, and each template names its nature in its opening line.

| Template | File | Nature |
| --- | --- | --- |
| Feature (LLD) | [feature.md](feature.md) | Truth |
| Package (one workspace package) | [package.md](package.md) | Truth |
| System (one machine spanning packages) | [system.md](system.md) | Truth |
| Architecture Decision (AD) | [architecture-decision.md](architecture-decision.md) | Truth (Decision Changelog tail sanctioned) |
| System overview | [system-overview.md](system-overview.md) | Truth |
| Domain model | [domain-model.md](domain-model.md) | Truth |
| Glossary | [glossary.md](glossary.md) | Truth |
| Non-goals | [non-goals.md](non-goals.md) | Truth |
| API reference | [api-reference.md](api-reference.md) | Truth |
| Environment registry | [environment-registry.md](environment-registry.md) | Truth |
| Security overview | [security-overview.md](security-overview.md) | Truth |
| Testing strategy | [testing-strategy.md](testing-strategy.md) | Truth |
| Behavioral checklist | [behavioral-checklist.md](behavioral-checklist.md) | Truth |
| UX behavior | [ux-behavior.md](ux-behavior.md) | Truth |
| Operations procedure | [operations-procedure.md](operations-procedure.md) | Truth |
| Implementation map | [implementation-map.md](implementation-map.md) | Truth |
| Bookkeeping ledger | [bookkeeping.md](bookkeeping.md) | Truth (work queue) |
| Protected files | [protected-files.md](protected-files.md) | Truth |
| Project root README | [root-readme.md](root-readme.md) | Truth |
| docs/README.md (doc index) | [docs-readme.md](docs-readme.md) | Truth |
| docs/structure.md (authority map) | [structure.md](structure.md) | Truth (Health Log tail sanctioned) |
| Plan | [plan.md](plan.md) | Record |
| Changelog entry | [changelog-entry.md](changelog-entry.md) | Record |
| Migration runbook | [migration-runbook.md](migration-runbook.md) | Record |
| Journal | [journal.md](journal.md) | Record (append-only) |
| CHANGELOG master index | [changelog-index.md](changelog-index.md) | Record index (append-only) |
| Backlog | [backlog.md](backlog.md) | Record (append-only) |
| Memory (main agent) | [memory-main.md](memory-main.md) | Record (append-only ledger) |

**The `type:` enum lives here.** A doc's `type:` frontmatter takes its value from this table — one genre per template (`feature`, `architecture-decision`, `non-goals`, …). External generators consume this list rather than defining their own; a type this table does not name defaults to `docs/architecture/` placement and is never added to the protected-files list.

**Baseline scaffolds** — files that must exist after every baseline; the `maintenance` agent (baseline mode) creates any that are missing: [docs-readme.md](docs-readme.md), [structure.md](structure.md), [changelog-index.md](changelog-index.md), [backlog.md](backlog.md), [memory-main.md](memory-main.md), and [root-readme.md](root-readme.md) (never overwriting an existing root README).

**Ownership.** Three genres carry code — **feature**, **package**, **system** — and each is the canonical reference for the code paths in its **`owns:` frontmatter**, the only ownership key. To find what a doc owns, read its `owns:` globs; to find the doc for a path, match the path against the injected ownership index (the union of every owning doc's globs), narrower glob wins. That is what layers them: a package doc claims `packages/{name}/**` and is the tree's **residual** owner, while a system doc claims the narrower subtrees of one machine and a feature doc claims one surface — both win those paths by specificity, and the package doc keeps everything neither claims. Two docs may never claim a path at **equal** specificity. Every other genre here owns no code, including the cross-cutting doctrine in `docs/architecture/common/`. See [`../references/frontmatter.md`](../references/frontmatter.md) for turning code into `owns:` globs.
