Skip to content

Refactor docs from test-harness tour to system-architecture tour#7

Merged
samkeen merged 1 commit into
mainfrom
claude/refactor-html-docs-architecture-yjhoos
Jul 1, 2026
Merged

Refactor docs from test-harness tour to system-architecture tour#7
samkeen merged 1 commit into
mainfrom
claude/refactor-html-docs-architecture-yjhoos

Conversation

@samkeen

@samkeen samkeen commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Reframe the HTML docs around how the index engine is constructed
rather than around the test suite's file/step layout, using the test
suite as ground truth for every claim.

  • Rename docs/test-harness-tour.html -> docs/architecture.html.
  • Organize by system architecture: the governing equation
    (index = projection of Markdown ∪ log), the three storage tiers,
    the crate/module layout, the substrate bet, the schema, then the
    data flows (ingest, notes/write discipline, chunks/links/graph,
    relation vocabulary, embedder seam, hybrid retrieval, suggestion
    lifecycle, event log/replay, and the Vault/CLI adapter).
  • Each layer cites the specific tests that pin it as ground truth,
    plus a single "Grounded in the tests" section that maps every
    architectural property to its covering test file.
  • Bring the doc current with the built system: 3 crates (adds
    b2-embed's real candle-backed LocalEmbedder), 73 passing tests,
    rustc 1.96.0, and the fail-fast model-mismatch / open()-never-
    mutates-vectors behavior.
  • Update the README link to point at the new doc.

Co-Authored-By: Claude Opus 4.8 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01265nrsLFg8VDWMrBXuUoba

Summary by CodeRabbit

  • Documentation
    • Added a new architecture guide with a full overview of the system, core components, data flow, and key invariants.
    • Updated the “Next up” README link to point to the new architecture page.
    • Removed the older test-harness tour page in favor of the new documentation.

Reframe the HTML docs around how the index engine is *constructed*
rather than around the test suite's file/step layout, using the test
suite as ground truth for every claim.

- Rename docs/test-harness-tour.html -> docs/architecture.html.
- Organize by system architecture: the governing equation
  (index = projection of Markdown ∪ log), the three storage tiers,
  the crate/module layout, the substrate bet, the schema, then the
  data flows (ingest, notes/write discipline, chunks/links/graph,
  relation vocabulary, embedder seam, hybrid retrieval, suggestion
  lifecycle, event log/replay, and the Vault/CLI adapter).
- Each layer cites the specific tests that pin it as ground truth,
  plus a single "Grounded in the tests" section that maps every
  architectural property to its covering test file.
- Bring the doc current with the built system: 3 crates (adds
  b2-embed's real candle-backed LocalEmbedder), 73 passing tests,
  rustc 1.96.0, and the fail-fast model-mismatch / open()-never-
  mutates-vectors behavior.
- Update the README link to point at the new doc.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01265nrsLFg8VDWMrBXuUoba
@coderabbitai

coderabbitai Bot commented Jul 1, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Free

Run ID: c3b58965-0410-4732-90af-58456190f72a

📥 Commits

Reviewing files that changed from the base of the PR and between 9a4ea14 and 3ebc011.

📒 Files selected for processing (3)
  • README.md
  • docs/architecture.html
  • docs/test-harness-tour.html

📝 Walkthrough

Walkthrough

Replaces docs/test-harness-tour.html with a new comprehensive docs/architecture.html page describing B2's system architecture, storage tiers, crates, ingest pipeline, embedder seam, retrieval, suggestion lifecycle, event log, and Vault façade. Updates README's "Next up" link accordingly.

Changes

Architecture documentation swap

Layer / File(s) Summary
README link update
README.md
Updates the "Next up" text and link from docs/test-harness-tour.html to docs/architecture.html.
Page skeleton and navigation
docs/architecture.html
Adds HTML structure, embedded stylesheet, layout container, and sticky sidebar navigation linking to all sections.
Overview and system model
docs/architecture.html
Adds hero overview, governing equation, and three-tier storage model sections.
Crates, substrate, schema
docs/architecture.html
Documents crate/module responsibilities, the SQLite/FTS5/sqlite-vec substrate requirement, and the derived schema tables.
Ingest, notes, graph modeling
docs/architecture.html
Documents ingest phases, note write discipline, chunk/link/graph modeling, and the relation vocabulary.
Embedder, retrieval, suggestions
docs/architecture.html
Documents the embedder trait/seam, hybrid retrieval fusion, and the suggestion accept/reject lifecycle.
Event log, Vault façade, invariants, backlog
docs/architecture.html
Documents event log/replay, the typed Vault façade and CLI, core invariants, deterministic seams, test grounding, backlog items, and page footer. Removes the entire old docs/test-harness-tour.html page.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Sequence Diagram(s)

Not applicable — this PR is a documentation-only change with no functional code flow.

Poem

A tour swapped out, a new page grew,
Architecture docs, crisp and true,
Tiers and chunks and edges bright,
Golden vaults replayed just right,
This bunny hops through HTML too! 🐇📄✨


Note

🎁 Summarized by CodeRabbit Free

The PR author is not assigned a seat. To perform a comprehensive line-by-line review, please assign a seat to the pull request author through the subscription management page by visiting https://app.coderabbit.ai/login.

Comment @coderabbitai help to get the list of available commands.

@samkeen
samkeen merged commit 20af557 into main Jul 1, 2026
1 check was pending
@samkeen
samkeen deleted the claude/refactor-html-docs-architecture-yjhoos branch July 1, 2026 13:59
samkeen added a commit that referenced this pull request Jul 13, 2026
… & graph)

Four decisions locked ahead of their slices (research §9b #7#10):
- chunk/centroid DDL = one-of nullable FKs on the single chunks table +
  a sibling resource_centroids table (CASCADE intact; FTS/embeddings
  keep one rowid space)
- similar/doc-ref anchors dispatch by extension (.md/b2id → note, else
  resource) — the §3 classification doctrine, one rule everywhere
- "unlinked" for a resource anchor = the same 1-hop exclusion,
  direction-agnostic (inbound-only by construction)
- façade grows list_resources; list_notes untouched

Stage B: specs/resources-inventory-graph.md — the slice-1 build spec
(v4 schema: resources table + edges dst_resource_path/embed/caption;
generalized walk with (size,mtime)-gated blake3 hashing and pruning;
parser forms with caption capture; doc_kind dispatch helper;
explain/mv over resources; desktop tree + fallback card + opener;
watcher allowlist→denylist inversion). tasks.md points at it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants