docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Add copy buttons to all
 blocks\n(function() {\n function addCopyButtons() {\n document.querySelectorAll('pre code').forEach(function(codeBlock) {\n if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;\n codeBlock.parentElement.setAttribute('data-copy-added', 'true');\n \n var btn = document.createElement('button');\n btn.textContent = 'Copy';\n btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';\n btn.onmouseover = function() { this.style.opacity = '1'; };\n btn.onmouseout = function() { this.style.opacity = '0.7'; };\n btn.onclick = function() {\n navigator.clipboard.writeText(codeBlock.textContent).then(function() {\n btn.textContent = 'Copied!';\n setTimeout(function() { btn.textContent = 'Copy'; }, 1500);\n });\n };\n codeBlock.parentElement.style.position = 'relative';\n codeBlock.parentElement.appendChild(btn);\n });\n }\n \n addCopyButtons();\n \n // Re-run on dynamic content\n var observer = new MutationObserver(addCopyButtons);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Add Copy Buttons to Code Blocks");
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Force GitHub README to respect dark mode\n(function() {\n var style = document.createElement('style');\n style.textContent = '\n .markdown-body {\n color-scheme: dark light;\n }\n .markdown-body pre { background: #161b22 !important; }\n .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; }\n .markdown-body table th, .markdown-body table td { border-color: #30363d !important; }\n .markdown-body img { background: #0d1117; }\n .markdown-body blockquote { border-left-color: #8b949e; }\n .markdown-body hr { border-color: #30363d; }\n ';\n document.head.appendChild(style);\n})();", "GitHub Dark Mode README Fix"); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Highlight search terms from Google/DuckDuckGo/Bing referrer\n(function() {\n var ref = document.referrer;\n var terms = [];\n \n if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) {\n var url = new URL(ref);\n var q = url.searchParams.get('q') || url.searchParams.get('p');\n if (q) {\n terms = q.split(/\\s+/).filter(function(t) { return t.length > 2; });\n }\n }\n \n if (terms.length === 0) return;\n \n var style = document.createElement('style');\n style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }';\n document.head.appendChild(style);\n \n function highlight(node) {\n if (node.nodeType === 3) { // text node\n var text = node.textContent;\n var found = false;\n terms.forEach(function(term) {\n var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\\]\\\\]/g, '\\\\') + ')', 'gi');\n if (regex.test(text)) {\n found = true;\n var frag = document.createDocumentFragment();\n var parts = text.split(regex);\n parts.forEach(function(part, i) {\n if (i % 2 === 0) {\n frag.appendChild(document.createTextNode(part));\n } else {\n var span = document.createElement('span');\n span.className = 'userscript-highlight';\n span.textContent = part;\n frag.appendChild(span);\n }\n });\n node.parentNode.replaceChild(frag, node);\n }\n });\n } else if (node.nodeType === 1 && node.childNodes) { // element\n var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT'];\n if (!skipTags.includes(node.tagName)) {\n Array.from(node.childNodes).forEach(highlight);\n }\n }\n }\n \n highlight(document.body);\n \n // Re-highlight on dynamic content\n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1 || node.nodeType === 3) highlight(node);\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Highlight Search Terms"); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Strip utm_, fbclid, gclid, etc. from all links on page\n(function() {\n var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content',\n 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid',\n 'ref', 'ref_src', 'source', 'medium', 'campaign'];\n \n function cleanUrl(url) {\n try {\n var u = new URL(url, window.location.origin);\n var changed = false;\n trackingParams.forEach(function(p) {\n if (u.searchParams.has(p)) {\n u.searchParams.delete(p);\n changed = true;\n }\n });\n return changed ? u.toString() : url;\n } catch (e) {\n return url;\n }\n }\n \n function cleanLinks() {\n document.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n \n cleanLinks();\n \n var observer = new MutationObserver(function(mutations) {\n mutations.forEach(function(m) {\n m.addedNodes.forEach(function(node) {\n if (node.nodeType === 1) {\n if (node.tagName === 'A') cleanLinks();\n node.querySelectorAll('a[href]').forEach(function(a) {\n var clean = cleanUrl(a.href);\n if (clean !== a.href) a.href = clean;\n });\n }\n });\n });\n });\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "Remove Tracking Parameters from Links"); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Auto-enable theater mode on YouTube\n(function() {\n function tryTheater() {\n var btn = document.querySelector('button[aria-label=\"Theater mode\"], ytd-player #player button[title=\"Theater mode\"]');\n if (btn && !btn.classList.contains('activated')) {\n btn.click();\n }\n }\n \n // Try immediately\n tryTheater();\n \n // Try after navigation (SPA)\n var lastUrl = location.href;\n setInterval(function() {\n if (location.href !== lastUrl) {\n lastUrl = location.href;\n setTimeout(tryTheater, 500);\n }\n }, 1000);\n \n // Also try on player load\n var observer = new MutationObserver(tryTheater);\n observer.observe(document.body, { childList: true, subtree: true });\n})();", "YouTube Theater Mode Default"); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Remove or un-stick sticky/fixed headers that block content\n(function() {\n function unstick() {\n document.querySelectorAll('header, nav, [role=\"banner\"], .header, .navbar, .sticky, .fixed-top, [style*=\"position: fixed\"], [style*=\"position:sticky\"]').forEach(function(el) {\n if (el.style.position === 'fixed' || el.style.position === 'sticky' || \n getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') {\n el.style.position = 'static';\n el.style.top = 'auto';\n el.style.zIndex = 'auto';\n }\n });\n }\n \n unstick();\n \n var observer = new MutationObserver(unstick);\n observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] });\n})();", "Kill Sticky Headers"); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude
, 'i'); if (__m === '*' || __re.test(location.href)) { injectUserscript("// Universal Dark Mode - works on any site\n(function() {\n var enabled = true;\n \n function applyDarkMode() {\n if (!enabled) return;\n \n // Create style element if it doesn't exist\n var style = document.getElementById('universal-dark-mode-style');\n if (!style) {\n style = document.createElement('style');\n style.id = 'universal-dark-mode-style';\n document.head.appendChild(style);\n }\n \n // Dark mode CSS - inverts colors but preserves images/video\n style.textContent = '\n /* Invert everything except media */\n html {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #1a1a2e !important;\n }\n \n /* Restore images, videos, iframes, canvas */\n img, video, iframe, canvas, svg, picture, [style*=\"background-image\"] {\n filter: invert(1) hue-rotate(180deg) !important;\n }\n \n /* Preserve specific elements that should not be inverted */\n .no-dark-mode, .no-dark-mode *,\n [data-theme=\"light\"], [data-theme=\"light\"],\n .ace_editor, .ace_editor *,\n .CodeMirror, .CodeMirror *,\n .monaco-editor, .monaco-editor *,\n .markdown-body pre, .markdown-body pre *,\n .highlight, .highlight *,\n pre code, pre code * {\n filter: none !important;\n }\n \n /* Fix common UI elements */\n .modal, .popup, .dropdown-menu, .tooltip, .popover {\n filter: invert(1) hue-rotate(180deg) !important;\n background: #2d2d44 !important;\n border-color: #444 !important;\n }\n \n /* Scrollbars */\n ::-webkit-scrollbar { background: #1a1a2e !important; }\n ::-webkit-scrollbar-thumb { background: #444 !important; }\n ::-webkit-scrollbar-thumb:hover { background: #555 !important; }\n \n /* Selection */\n ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; }\n ';\n }\n \n function removeDarkMode() {\n var style = document.getElementById('universal-dark-mode-style');\n if (style) style.remove();\n }\n \n // Toggle with Alt+Shift+D\n document.addEventListener('keydown', function(e) {\n if (e.altKey && e.shiftKey && e.key === 'D') {\n e.preventDefault();\n enabled = !enabled;\n if (enabled) {\n applyDarkMode();\n console.log('[Universal Dark Mode] Enabled');\n } else {\n removeDarkMode();\n console.log('[Universal Dark Mode] Disabled');\n }\n }\n });\n \n // Apply on load\n applyDarkMode();\n \n // Re-apply on dynamic content\n var observer = new MutationObserver(function(mutations) {\n if (enabled && !document.getElementById('universal-dark-mode-style')) {\n applyDarkMode();\n }\n });\n observer.observe(document.head, { childList: true });\n \n console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle');\n})();", "Universal Dark Mode"); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor - #14855

Merged
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts
Sep 3, 2026
Merged

docs(pm-dispatch): collapse CLAUDE.md's four excerpts to rule, hook and anchor#14855
os-zhuang merged 2 commits into
mainfrom
claude/issue-14685-claude-md-excerpts

Conversation

@os-litant

Copy link
Copy Markdown
Collaborator

Part of #14685
Part of #13597

Item 3 of decision batch 3, ruled B. Verbatim from ruling comment 5520452691:

B — each of CLAUDE.md's four hand-copied excerpts collapses to one ⛔ rule sentence, the enforcing hook or override switch, and a pointer to the AGENTS.md anchor (about 30 lines). The two measured drifts (C4's "§9" pointer, C5's "~18 merges" figure the anchor does not carry) are fixed under this ruling. The charter sentence "the four rules are inlined here" is rewritten to say each is inlined as one sentence — the maintainer has ruled that change.

Governed surface (CLAUDE.md): this PR stays draft, no reviewers requested, no ready flip, no enqueue. The dispatching seat runs contract review and then requests human review.

Scope

One file: the repo-root CLAUDE.md. Nothing else in the tree is touched. AGENTS.md, the hooks and objectui's CLAUDE.md are explicitly out of scope for this flight.

Counts

Token convention is ceil(utf8 bytes / 4) — the convention scripts/check-skills-token-ratchet.mjs declares as TOKEN_CONVENTION (line 184), used here so the number is comparable with the published-skill ledger even though this file is not in that ledger.

filelines beforelines afterlines deltatokens beforetokens aftertokens delta
CLAUDE.md8636-501369524-845

Whole-PR total is the same row: one file changed. Line ratchet ceiling for CLAUDE.md stays 86 — not edited here (the re-lock is a separate pass after all four flights).

Site by site

Line numbers on the left are origin/main at f3ae441fa2, where the file was 86 lines.

sitebeforeafterwhat happened
charter, :1-64 prose lines3 prose linesruled rewrite: the sentence now says each of the four rules is inlined as one sentence, its enforcing hook, and a pointer to the AGENTS.md heading, instead of "the four rules ... are inlined here because missing any one of them wastes or corrupts other agents' work"
C2 claim-the-issue, :8-2112 body lines4 body linesrule sentence kept (assign plus a claim comment carrying session ID and branch; re-read the comments); dropped the gh invocation, the "burn the same hours twice" narrative and the "implemented twice in one morning" incident; one clause now states there is no hook; pointer added
C3 worktree-first, :23-4218 body lines5 body linesrule sentence kept (never edit a shared primary checkout, this repo's or a sibling's; one worktree per task per repo); dropped the fenced git worktree add recipe and the fail-open/precedence commentary; both hooks and OS_ALLOW_MAIN_EDITS=1 kept on one line; pointer added
C4 never-stash, :44-7126 body lines5 body linesrule sentence kept (refs/stash is in the common .git dir, one shared LIFO stack, pop reports success); dropped the fenced replacement recipes, the four-ref-namespace enumeration and the incident narrative; hook, OS_ALLOW_STASH=1 and the self-test kept on one line; pointer added
C5 releases, :73-839 body lines4 body linesrule sentence kept (written centrally at release time, never a row per PR; a factual error is a docs-only PR or an issue); dropped the conflict-magnet narrative; the changeset input is named in place of a hook; pointer added
closing pointer, :85-862 lines1 linekept as a pointer, rewrapped to one line

Four ## headings are byte-identical to origin/main — verified with diff over grep '^## ' on both sides, so any grep or tooling that names a heading keeps working. Repo-wide grep for each heading text finds only CLAUDE.md itself, so no script or hook reads them today.

The two ruled drift fixes

  • C4 drift — the "AGENTS.md §9" pointer. The shared-refs/remotes fact it pointed at lives in the unnumbered preface of ## Multi-agent working discipline, not in any numbered section; §9 resolved to nothing. The pointer is now spelled by heading text. The refs/remotes fact itself stays in AGENTS.md, which is where it is maintained.
  • C5 drift — "~18 merges to main in a working day". A statistic the AGENTS.md anchor does not carry (the anchor row says "three PRs raced the same table inside one afternoon"). It left with the narrative it lived in; nothing in CLAUDE.md now states a merge-rate figure.

Every pointer resolves

Measured at this PR's head with grep -n in AGENTS.md. Headings are cited by text, never by line number; the lines below are evidence, not the pointer.

pointer written in CLAUDE.mdAGENTS.md match at head
Multi-agent working discipline, its paragraph Claim the issue BEFORE you write any code.380:## Multi-agent working discipline and 459:**Claim the issue BEFORE you write any code.** Assign it to yourself
Prime Directives, directive 11191:## Prime Directives and 241:11. **Worktree-first — never edit on the shared `main` checkout.**
Multi-agent working discipline (stash)380:## Multi-agent working discipline; the rule is that section's opening paragraph, 385:**⛔ `git stash` is the sharpest thing the worktree does NOT isolate — never run a bare
Documentation Guardrails, its content/docs/releases/ row721:## Documentation Guardrails and ``726:

Every hook named exists

ls .claude/hooks/ at head:

  • .claude/hooks/guard-main-checkout.sh — its header line 3 reads "Blocks Edit / Write / NotebookEdit unless the file being edited lives in a dedicated ..."; OS_ALLOW_MAIN_EDITS at :23.
  • .claude/hooks/guard-main-checkout-bash.shOS_ALLOW_MAIN_EDITS at :95.
  • .claude/hooks/guard-shared-stash.shOS_ALLOW_STASH at :70.
  • .claude/hooks/guard-shared-stash.selftest.sh — referenced as "its .selftest.sh".

Gates

Derived at the final head, quoting the derivation line:

dispatch-gates: gate list derived from the tree of 'objectstack-ai/objectstack' at commit 94f328e8ff (/home/user/objectstack-14685-item3).
dispatch-gates: change set derived from git — 1 path(s) vs merge base 5ff5f9576 of 'origin/main' and HEAD
(committed 1, working tree 0, untracked 0; three-dot semantics, never 'origin/main..HEAD')
· CLAUDE.md

All runs below are at head 94f328e8ff (after git merge origin/main, no rebase). Exit codes captured by redirect before any pipe.

gateexitits own verdict line
pnpm check:pm-skill-ratchet (line ratchet)0✓ check-skill-line-ratchet: CLAUDE.md is 36 lines (ceiling 86; headroom 50). and ✓ check-skill-line-ratchet: CLAUDE.md: widest table row is 0 bytes (pin 0; headroom 0).
pnpm check:agent-test-spelling0✓ check-agent-test-spelling: 0 violations — 430 file(s) · 5704 bare `--` token(s) · 1381 launcher-rooted run(s) · 9 separator(s) JUDGED · 5 vitest-backed script name(s) derived from 81 manifest(s)
pnpm check:pm-governed-merges0✓ check-governed-merges --self-test: 241 assertions (...)
pnpm check:skill-frame-sync0✓ check-skill-frame-sync: 4 copies of the decision frame are structurally isomorphic across 3 files
token ratchet (node scripts/check-skills-token-ratchet.mjs --self-test then the scan)0✓ check-skills-token-ratchet: 36 authored bundle file(s) within their ceilings; 11 generator-owned file(s) measured, not ratcheted.
pnpm check:nul-bytes0check-nul-bytes: OK (scanned 8072 text file(s) -- 8072 tracked, 0 untracked-not-ignored; skipped 7 binary; no raw ASCII control bytes).
pnpm check:role-word0check-role-word: OK, no new occurrences of the reserved word.
pnpm check:corpus-claim-drift0check-corpus-claim-drift: OK, no new claim sites beside a pinned spelling.

Also run outside any gate, since the file was edited: grep -naP for raw ASCII control bytes over CLAUDE.md — no match (exit 1).

NOT MEASURED, and why

  • Token ratchet does not cover CLAUDE.md. It reports 36 authored bundle file(s), all under skills/**; grep -c CLAUDE.md over its full output is 0. Its green says nothing about this file. The token numbers in the counts table above are computed by hand under the same convention, not read from this gate.
  • check:role-word and check:corpus-claim-drift do not read CLAUDE.md either. Both print their own population: Scanned: 224 .md/.mdx file(s) read across 2 root(s) — content/docs 190, skills 34. The repo root is not one of those roots. They are green and they are green about other files; they are listed because the flight brief named them, and they are reported here as not measuring this change.
  • No repo-wide pnpm lint run. ESLint's population is JS/TS; this PR changes one Markdown file and adds, removes or moves no code, so no ESLint judgement about any file can change. Reported as a narrowing, not as a pass.
  • CI is not awaited. Per the dispatch contract the report is delivered at draft-PR time; the always-runs tail named by dispatch-gates is CI's to run.

Judgement calls

  1. 36 lines, not "about 30". Ruling B says "about 30 lines"; the flight brief permits up to 40 provided every kept line is a rule, a hook or a pointer. Every line here is one of those three. Getting to 30 exactly would have cost either a hook name, an override switch or a pointer.
  2. The refs/remotes sub-fact left CLAUDE.md with the stash narrative. It was a parenthetical inside the C4 excerpt (the one carrying the §9 drift), not one of the four rules. Under B it collapses out; it is unchanged in AGENTS.md.
  3. The ADR-0087 registries dropped from the releases block. The ruled shape names one input; the changeset is the one that applies to every PR. The registries stay in the AGENTS.md anchor row.
  4. The closing "See AGENTS.md" line was kept, rewrapped to one line. It is a pointer, which the ruled shape admits, and removing it is not something the ruling asks for.
  5. Headings kept verbatim including the and the "(AGENTS.md Prime Directive Migrate documentation site to Fumadocs with monorepo structure and shared content #11)" suffix on the worktree heading, which is accurate at head.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1


Generated by Claude Code

…+ anchor
Each of the four hand-copied excerpts becomes one rule sentence, the enforcing
hook and its override switch, and a pointer to the AGENTS.md heading that
carries the full rule. The charter sentence now says each rule is inlined as
one sentence rather than that the rules are inlined.
Both measured drifts go with the narratives they lived in: the "AGENTS.md §9"
pointer (the shared-refs rule lives in the unnumbered preface of "Multi-agent
working discipline", not in a numbered section) and the "~18 merges in a
working day" figure the AGENTS.md anchor does not carry. Incident narratives,
command blocks and statistics stay in AGENTS.md, which is where they are
maintained.
86 -> 36 lines. The four headings are byte-identical so greps that name them
keep working; the ratchet ceiling is not touched.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LraLgQVGq8egUwfYZpbYt1
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentationImprovements or additions to documentationsize/sskip-changesetPR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@os-litant@os-zhuang@claude