Make TeaAgent's documentation corpus useful for daily users, maintainers, and future agents by reducing status drift, clarifying current truth, and turning review insight into executable work.
This plan optimizes for:
- User trust.
- Runtime and documentation stability.
- Agent maintainability.
- Risk visibility.
- Cost-effective governance.
Do not aggressively merge historical docs. Historical evidence is valuable. The high-ROI move is to create a small number of trusted entry points and make volatile claims harder to stale silently.
| Investment | Cost | ROI | Reason |
|---|---|---|---|
Curated docs/INDEX.md |
Low | High | Reduces search cost immediately. |
| Fix stale current-status claims | Low | High | Prevents direct user and maintainer confusion. |
| Operating model for claims and freshness | Low | High | Gives future agents reusable rules. |
| Guarded volatile prose claims | Medium | High | Prevents the most damaging doc/test contradictions. |
| Generated exhaustive docs index | Medium | Medium | Useful after the curated model stabilizes. |
| Full semantic stale-claim parser | High | Medium | Valuable but brittle; defer until targeted guards prove useful. |
| Mass merge of dated docs | High | Low | Destroys evidence and creates review risk. |
| Priority | Theme | Goal |
|---|---|---|
| P0 | Current-truth repair | Remove known misleading status claims and create front doors. |
| P1 | Drift prevention | Add guardrails for volatile claims and status ownership. |
| P2 | Automation and scale | Generate inventories, link checks, stale dashboards, and release bundles. |
Status: Done in this pass.
Files:
docs/INDEX.md
Acceptance criteria:
- Current-truth, governance, plan, evidence, security, reliability, guide, and reference front doors are linked.
- Dated-doc reading rules are explicit.
- Validation commands are listed.
Status: Done in this pass.
Files:
docs/acceptance.md
Acceptance criteria:
- The stale
3255 passed, 26 failed, 76 skippedparagraph no longer appears as current status. - Acceptance count remains
441 passed. - Full-suite evidence is clearly labeled as dated evidence, not current release proof.
Status: Done in this pass.
Files:
docs/analysis/total-review-2026-06-04-INDEX.mddocs/analysis/total-review-real-situation-2026-06-04.mddocs/analysis/total-review-claim-verification-2026-06-04.mddocs/analysis/total-review-critique-and-interrogation-2026-06-04.mddocs/analysis/total-review-future-outlook-2026-06-04.md
Acceptance criteria:
- English headings.
- No generation artifact tags.
- Baseline commit and current inventory are not conflated.
Status: Done in this pass.
Files:
docs/modules/INDEX.md
Acceptance criteria:
- The generated module index warns readers that its risk summary is inventory, not current closure truth.
- The stale memory-derived bug list is replaced with current front-door links.
Status: Done in this pass.
Files:
docs/governance/documentation-operating-model-2026-06-04.md
Acceptance criteria:
- Defines claim classes, evidence hierarchy, freshness windows, guarded claims, merge policy, and documentation definition of done.
Status: Done.
Files:
docs/roadmap-status.mddocs/plans/documentation-optimization-master-plan-2026-06-04.mddocs/work-log/documentation-optimization-work-items-2026-06-04.md
Acceptance criteria:
- H0 claim and risk hygiene explicitly references documentation-current-truth work.
- Doc-vs-HEAD guard work has a roadmap row or work-item link.
Status: Done.
Goal:
Create a small registry of volatile doc claims that must be checked by CI.
Initial claim types:
- Acceptance count.
- Full-suite result if stated as current.
- Provider count.
- Base dependency audit status.
- Optional-extra dependency audit status.
- Release-readiness claims.
Acceptance criteria:
- Registry format documented. ✅ (
docs/governance/guarded-claims-registry.md) - At least one prose full-suite claim is guarded. ✅ (
validate_guarded_claimsenforces full-suite failure prose on README, acceptance, daily-driver-current-status, roadmap-status) - A deliberately stale acceptance/full-suite phrase fails the test. ✅ (
GUARDED_STALE_FAILURE_PROSEregex rejectsN failedwithN > 0)
Status: Proposed.
Goal:
Ensure P0/P1 module risks link to a central risk register, roadmap row, ticket, or explicit defer decision.
Acceptance criteria:
- Every High/Critical module risk has an upward link or documented defer.
docs/modules/INDEX.mddistinguishes "inventory risk" from "active risk."
Status: Done.
Goal:
Prevent roadmap rows from losing owner, status, confidence, next gate, or exit evidence fields.
Acceptance criteria:
docs/roadmap-status.mdtable rows are parsed.- Missing required fields fail a docs test.
- Status values map to
document-state-model.md.
Status: Done.
Goal:
Resolve the stale "six proposed ADRs" claim by checking the ADR source of truth and closing the index drift.
Acceptance criteria:
- ADR 0010, 0012, 0014, 0015, 0017, and 0018 are no longer represented as Proposed in the ADR index.
- ADR 0025 reflects the implemented REPL and TUI controller state.
- ADR index categorizes ADR 0025 under chat surfaces.
Status: Done.
Goal:
Give every coverage omit pattern a reason, owner surface, and target re-entry sprint.
Acceptance criteria:
- 16 omit patterns listed.
- Each has reason, risk, owner surface, target, and first smoke-test candidate.
scripts/validate_docs_consistency.pychecks the ledger againstpyproject.toml.
Status: Done.
Goal:
Preserve the zero-dependency base claim while governing optional extras such as managed runtimes and web stacks.
Acceptance criteria:
- Base audit and optional-extra audit scopes are documented separately.
- Security workflow or nightly job has a clear optional-extra audit plan.
- Security workflow uses a base lockfile export for PR gating and a non-blocking optional-extra matrix for scheduled/manual visibility.
Status: Done.
Goal:
Generate an exhaustive docs inventory after the curated index stabilizes.
Acceptance criteria:
- Script generates deterministic inventory.
- Generated output says it is not the current-truth source.
- Stale generated output fails only when the generator is part of CI.
Status: Done.
Goal:
Detect broken internal links across Markdown without blocking normal work on low-risk historical docs.
Acceptance criteria:
- Internal links in current-truth docs are blocking.
- Historical evidence links are reported first, then optionally made blocking.
Status: Done.
Goal:
Show which current-truth docs have not been reviewed after relevant code changes.
Acceptance criteria:
- Current-truth docs have review triggers.
- Dashboard groups stale docs by owner surface.
Status: Done (2026-06-06).
Goal:
Before release, produce a compact evidence bundle covering test status, dependency audit scope, roadmap status, known risks, and documentation freshness.
Acceptance criteria:
- Release checklist links the bundle.
- Bundle includes commands, dates, commits, and residual risks.
| Risk | Impact | Mitigation |
|---|---|---|
| More docs create more drift | Medium | Every new doc must be linked from a front door or marked historical. |
| Validators become brittle | Medium | Guard high-value claims first; avoid parsing arbitrary prose. |
| Current-truth docs become too long | High | Move history to analysis; keep user docs operational. |
| Generated indexes become unreadable | Medium | Keep curated index primary; generated inventory secondary. |
| Module risks stay unmanaged | High | Require upward links for P0/P1 module risks. |
| Roadmap remains stale | High | Add documentation-current-truth rows to H0 and require exit evidence. |
Run after this documentation pass:
python3 scripts/validate_docs_consistency.py
python3 -m pytest tests/test_docs_consistency.py tests/acceptance/test_docs_acceptance_count_accuracy.py -qRecommended later:
cx overview docs --limit 120
cx symbols --kind heading --name '*Status*' --limit 120
cx symbols --kind heading --name '*Risk*' --limit 120
cx symbols --kind heading --name '*Roadmap*' --limit 120Documentation optimization is successful when:
- A reader can find current truth from
docs/INDEX.mdin less than five minutes. - No stable current-truth doc contains a known stale test, safety, release, or roadmap claim.
- High-severity risks have owners or explicit defer decisions.
- Roadmap rows have exit evidence.
- Dated evidence remains preserved but clearly scoped.
- Future agents can add docs without inventing a new status system.