Skip to content

docs(claude-md): relocate the narrative to documentation/agent-notes.md - #34

Merged
NSchatz merged 1 commit into
mainfrom
chore/claude-md-audit
Aug 4, 2026
Merged

docs(claude-md): relocate the narrative to documentation/agent-notes.md#34
NSchatz merged 1 commit into
mainfrom
chore/claude-md-audit

Conversation

@NSchatz

@NSchatz NSchatz commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

CLAUDE.md was 51,276 bytes and is always-read by every worker that enters this repo, so its cost is paid per worker before a line of code is read. This relocates the narrative and keeps the rules.

Governed by the 2026-08-04 amendment to the meta-repo's ADR 0023, which bounds <submodule>/CLAUDE.md and names <repo>/documentation/agent-notes.md as the relocation target. The bound itself is deliberately not quoted in either file: it is a per-repo ratchet (REPO_CLAUDE in doc-budget.mjs) that is lowered as relocations land, and the first number quoted for it went stale within a day. This repo was never near it anyway; the per-worker token cost is the forcing function.

What moved

documentation/agent-notes.md (new, 50,216 B) receives the per-incident write-ups, the shipped-phase histories and the long rationales verbatim, under headings that name where they came from:

section what it holds
The docs sidebar and the IA spine the four-day site outage and the refuted API-Reference placement claim
The pre-commit PHI gate and git mv the R100/C100 hole, the three unclosed escapes, the vacuity traps
The em-dash brand gate the NUL-exclusion reasoning and the em-dash-as-a-value defect
The vendor to npm dependency swap the ERESOLVE, the static guard, the npx fault
Shipped phases P1 through P7, as each was recorded on landing
Branch protection the ruleset, the context table, the per-check reasoning
The attw wrapper both nets, the six packed-but-undeclared declarations
No internal project bookkeeping on a public surface the four-surfaces boundary and why it rests on the convention

agent-notes.md is deliberately outside the format:check glob. Prettier renormalises list indentation and would rewrite the archive whose verbatim preservation this slice rests on. The file says so, in itself. Do not add it.

What stayed

The cursor (what this package is, its status, its stack), the rules, and every trap, each compressed to a one-line imperative with a link to the section that proves it. Nothing was deleted to hit a number.

51,276 -> 29,451 bytes (-43%).

Checks run

  • Heading preservation: every ## heading in the original exists in one of the two files. None lost.
  • Verbatim relocation: all 17 relocated blocks (499 of 602 original lines) are byte-identical substrings of agent-notes.md.
  • Coverage: all 297 sentences of the original accounted for; the only text not carried verbatim is recorded in agent-notes.md under "Corrections made during the relocation".
  • Deliberate-omission traps checked by hand, since they carry no identifier a mechanical check can see: the three unclosed PHI escapes, the two disclosed attw holes, the un-truncated CR-frame hit, the two diagnostics that deliberately do not say "install it", the cli bin alias that is deliberately not added, the MCP tools not yet exposed, redact never being a partial scrub, and archived doc versions reporting at info. All carried.
  • Pointers: all 11 anchor links resolve.
  • format:check, check:no-emdash (11 binary files excluded, the tell still reads 11), check:no-internal-refs: green.

Two claims changed rather than moved, both recorded

  • The Tech Stack runtime-deps bullet was pre-swap and contradicted Status (it listed @cosyte/fhir and @cosyte/transform as hard vendored deps). It now states the shipped shape, verified against package.json; the stale wording is quoted in agent-notes.md rather than dropped.
  • The FIXED at 0.0.3 version literal is not carried across: the registry and package.json both read 0.0.4. The trap itself is live and unchanged and is now stated without a number, per ADR 0023's own reason for deleting the umbrella's version list. @cosyte/fhir is still absent from the manifest because fhir cannot publish, and the manifest was not touched.

Gate

gate-refuter, three passes (ADR 0016 cap), all NOT REFUTED. Pass 1 cleared the relocation and raised four minor findings; pass 2 cleared the remedy and raised three more; pass 3 cleared that remedy and found nothing blocking. Every finding was fixed rather than argued away.

Docs only: no published surface changes, so no changeset and no version bump.

CLAUDE.md was 51,276 bytes and is always-read by every worker that enters
this repo. The per-incident write-ups, the shipped-phase histories and the
long rationales move to documentation/agent-notes.md verbatim, under headings
that name where they came from. Nothing is deleted.

What stays in CLAUDE.md is the cursor, the rules, and every trap, each
compressed to a one-line imperative with a link to the section that proves it.
51,276 -> 29,451 bytes.

Two things recorded rather than silently changed, both in the new file's
"Corrections made during the relocation" section:

- The Tech Stack runtime-deps bullet was pre-swap and contradicted Status
  (it listed @cosyte/fhir and @cosyte/transform as hard vendored deps).
  It now states the shipped shape, verified against package.json; the stale
  wording is quoted in agent-notes.md rather than dropped.
- The "FIXED at 0.0.3" version literal is not carried across: the registry
  and package.json both read 0.0.4 on 2026-08-04. The trap itself is live
  and unchanged and is stated without a number, per ADR 0023.

Per the 2026-08-04 amendment to the meta-repo's ADR 0023, which bounds
<submodule>/CLAUDE.md and names <repo>/documentation/agent-notes.md as the
relocation target. The bound itself is deliberately not quoted anywhere in
either file: it is a per-repo ratchet in REPO_CLAUDE in doc-budget.mjs that
is lowered as relocations land, and the first number quoted for it went
stale within a day.

documentation/agent-notes.md is deliberately outside the format:check glob.
Prettier renormalises list indentation and would rewrite the archive whose
verbatim preservation this slice rests on. Do not add it.

Docs only: no published surface changes, so no changeset and no version bump.
@NSchatz
NSchatz force-pushed the chore/claude-md-audit branch from fb1c4d7 to 81ea7b9 Compare August 4, 2026 22:20
@NSchatz
NSchatz merged commit d01696d into main Aug 4, 2026
7 of 8 checks passed
@NSchatz
NSchatz deleted the chore/claude-md-audit branch August 4, 2026 22:22
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.

1 participant