Repository navigation
docs: add the generated codebase-understanding tree - #1
Merged
Merged
Conversation
Sixteen cross-linked pages under docs/ documenting the codebase for a reader who has never opened it: architecture (overview, module map, data flow), reference (36 CLI subcommands, 14 MCP tools + 2 resources, top-30 library symbols), behavior (8 processes, 3 state machines), diagrams (components, dependencies, sequences), and five insights pages (impact analysis, debugging guide, contract map, business logic, tech debt). docs/README.md is the landing page. Every page frames memhtml as software an agent operates on an external $MEMHTML_ROOT; the repo itself stores no memory. All 1,722 path:LOC citations were mechanically verified to resolve in range. The analysis/ tier (ownership, hotspots, dead code) is intentionally omitted: four days of single-author history carries no signal. apps/docs (Astro site) is out of scope for this tree.
A prose-only pass over all 17 pages. Aphorisms, dramatic-reveal colons, 'not X, it's Y' contrasts, moralized failure phrasing, and announced-importance adverbs are rewritten as plain statements of what the code does. No fact, table row, code fence, Mermaid block, or citation changed: the citation set of every page is byte-identical to the pre-edit snapshot, and the remaining em dashes sit inside verbatim source quotes.
Comment-only edits across 130 files in apps/cli, apps/mcp, apps/consolidator, and the nine packages. Every file keeps its exact line count, so every path:LOC citation in the docs tree and in other comments stays valid. String literals are untouched, including tool descriptions, prompts, and guide topics. Verified: zero non-comment lines in the diff, typecheck 27/27, lint clean, agents-doc --check passes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this adds
Sixteen cross-linked Markdown pages under
docs/, plus a landingdocs/README.md, documenting the codebase for a reader who has never opened it. The tree was generated by a fleet of parallel documentation agents, one per page, and then mechanically verified.Two facts frame every page:
memhtml manifestdiscovery, generatedAGENTS.md.memhtml root($MEMHTML_ROOT), which memhtml manages with git: the root's tree is the system of record,.memhtml/index.dbis a rebuildable projection.apps/docs(the Astro site) is deliberately out of scope.Contents
The
analysis/tier (ownership, risk hotspots, dead code) is intentionally omitted: four days of single-author history carries no signal, and no dead-code tool is configured.Verification
path:LOCcitations were extracted and checked mechanically: every cited file exists and every line number is in range.Drift found in existing docs while generating (not fixed in this PR)
apps/cli/src/run.ts:178-179says "thirty-one commands" andapps/cli/src/commands.ts:1031says "33"; the table and the live binary both report 36.docs/backlog.md:50-53,ROADMAP.md:579-580, and spec requirement DOCSYNC-1 agree on "16 of 31 response types";RESPONSE_TYPESnow holds 32 members.RUNBOOK.md:243citesoperations.ts:1415for thetrace linksrefusal; it now lives atapps/cli/src/operations.ts:1681-1685.ERR_INDEX_STALEis declared inERROR_CODESwith no producer anywhere (consistent with the append-only policy, flagged for awareness).