Skip to content

docs(adr): drop all section numbering; reference sections by name only - #610

Merged
alpergundogdu merged 2 commits into
mainfrom
claude/adr-ban-section-numbers
May 19, 2026
Merged

alpergundogdu merged 2 commits into
mainfrom
claude/adr-ban-section-numbers

Conversation

@alpergundogdu

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #605. Eliminates the numeric-section anti-pattern corpus-wide — a renumber silently breaks every §N (the #590 ADR-026 split already caused drift).

  • Stripped leading numbering from all 154 section headings (### 2. FeeRouter split → ### FeeRouter split).
  • Rewrote every anchored link (182 anchors + 47 link-texts) to the de-numbered slug; resolved 195 bare + 19 code-block §N → § <Section Name>.
  • Anchor map built from the pristine numbered state, so all 1562 links still resolve (validated: 0 unresolved). §N == 0 except the one external-spec citation RFC 8446 §4.2.10 (intentionally exempt).
  • Guard swap: check-section-spacing → check-no-section-numbers — bans numeric §N and numbered headings, scans code blocks too (drift is identical there), RFC/EIP/BIP § exempt. Makefile + ADR-book-check CI job updated; pre-commit picks it up via check-refs.

Judgment calls (decided from canonical content — un-numbered docs, no deterministic target)

Site Decision
003 zero-voucher close ×2 dropped dangling §1 (003 unnumbered; section link is the ref)
018 buyback dropped dangling §1 (ADR-026 link is the ref)
026 pre-launch gauge dropped stray §2 before the explicit [Pre-launch gauge accumulation] link
034 code comments (split from 026 by #590) §2→ADR 026 § FeeRouter split, §9→ADR 026 § Governance; ADR 009 §44 (typo) → ADR 009 § Production: ve-Weighted Governance
appendix-operator-key-rotation dropped bogus ADR 001 §340–342 (no such section; ADR-001 link is the ref)
2 pre-existing broken anchors 019#phase-5--accepting-paid-delivery (em-dash slug), 016#feerouter (no #feerouter-production heading)
architecture.md "Chapter N —" labels left as-is (navigational, not §-referenced; de-numbering → 8 identical headings)

Test plan

  • make -C adr check-refs green; new check-no-section-numbers passes; negative controls flag §5 + ## 7. Heading, RFC exempt
  • 0 unresolved anchors across 1562 links (slugs recomputed from final state)
  • 0 numbered headings; 0 numeric §N (RFC exempt); markdownlint 0 errors
  • CI green

Eliminates the numeric-section anti-pattern corpus-wide (a renumber
silently breaks every §N; #590's split already caused drift):

- Strip leading numbering from all 154 section headings
  (### 2. FeeRouter split -> ### FeeRouter split).
- Rewrite every anchored link (182 anchors + 47 link-texts) to the
  de-numbered slug; resolve 195 bare + 19 code §N to § <Section Name>.
- Anchor map built from the pristine numbered state, so all 1562
  links still resolve (validated: 0 unresolved); §N == 0 except the
  one external-spec citation (RFC 8446 §4.2.10, intentionally exempt).

Swap guard: check-section-spacing -> check-no-section-numbers
(bans numeric §N AND numbered headings; scans code blocks too since
the drift is identical there; RFC/EIP/BIP § exempt). Makefile + the
ADR-book-check CI job updated; the pre-commit adr-ref-hygiene hook
picks it up via the check-refs aggregate.

Judgment calls in un-numbered docs (no deterministic target; decided
from canonical content):
- 003 zero-voucher close x2: dropped dangling " §1" (003 has no
  numbered sections; the section link is the reference).
- 018 buyback: dropped dangling " §1" (ADR 026 link is the ref).
- 026 pre-launch gauge: dropped stray "§2 " before the explicit
  [Pre-launch gauge accumulation] link.
- 034 VotingEscrow code comments (split out of ADR 026 by #590):
  §2 -> "ADR 026 § FeeRouter split", §9 -> "ADR 026 § Governance";
  "ADR 009 §44" (typo; 009 has no such section) ->
  "ADR 009 § Production: ve-Weighted Governance" (its delegation
  section).
- appendix-operator-key-rotation: dropped bogus "ADR 001 §340-342"
  (no such section; the ADR-001 link is the ref).

Also fixed two pre-existing broken anchors surfaced by validation:
appendix-observability -> 019 #phase-5--accepting-paid-delivery
(em-dash slug), 009 -> 016 #feerouter (no #feerouter-production
heading exists).

"Chapter N — ..." reading-order labels in architecture.md are left
as-is (navigational, not §-referenced; de-numbering would create 8
identical headings).

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@github-actions

github-actions Bot commented May 19, 2026 •

Copy link
Copy Markdown

Coverage report

Total: 89.67% (was 89.66%, ▲ +0.01%) — 16071/17923 lines

No Rust files changed in this PR.

History
Commit Total Δ vs base
5c43ef0 89.68% ● 0.00%
4c26d85 (HEAD) 89.67% ▲ +0.01%

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request standardizes the project's documentation by removing section numbers from headings across all Architecture Decision Records (ADRs) and updating internal cross-references to use section names. It also introduces a new Makefile check to enforce this style. Feedback identified a few regressions caused by the mass updates, including a broken anchor link, an accidental deletion of a numeric value in a heading, and a malformed section reference.

Comment thread adr/009-governance.md Resolved
Comment thread adr/012-client.md Resolved
Comment thread adr/appendix-blob-cache-eviction.md Resolved
- 012-client.md: restore "#### 256 MiB" (de-numbering regex wrongly
  treated the value "256" as a section number → "#### MiB"). No
  inbound links to the slug, so heading-only restore.
- appendix-blob-cache-eviction.md: pristine "§§2–4" was a section
  RANGE; the bare-§ handler only rewrote the first token, leaving
  "§[§ …](…)–4". Replaced with explicit named links to the three
  sections (Operator pinning / Operator-evict / Probe-hold).
- 009-governance.md: the pre-existing-broken "#feerouter-production"
  fix targeted "#feerouter"; the boostFloor / 20%-node-base-floor
  cashflow invariant actually lives under "#### Contract: FeeRouter"
  → corrected to "#contract-feerouter" (Gemini's target was right;
  its "link is broken" claim was not — #feerouter does resolve).
- Makefile: harden check-no-section-numbers so a value heading like
  "#### 256 MiB" (integer, no period) is not flagged as a numbered
  section; only "N. Title" / "N.M Title" forms are.

Re-validated: pandoc oracle 0 unresolved, check-refs green (refined
guard passes; negative-control flags ## 2./### 1.3 but not 256 MiB),
markdownlint 0. Audited corpus-wide: these were the only instances of
each class.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
@alpergundogdu
alpergundogdu merged commit a74ef07 into main May 19, 2026
11 checks passed
@alpergundogdu
alpergundogdu deleted the claude/adr-ban-section-numbers branch May 19, 2026 17:43
thiras pushed a commit that referenced this pull request Jul 25, 2026
… vector

Rebased onto main after #1456 landed the min-reputation rejection-floor
removal (#1438). The code removal, ADR 001's "graded weight, not a veto"
paragraph, ADR 037's candidate-pool wording, and the CHANGELOG entry are all
already on main and are dropped from this branch. What remains are the stale
reference sites #1456 did not cover, plus one #1418 left behind.

ADR 039 § Source set and selection. The floor was the only path by which
reputation entered multi-source admission. #1456 removed the floor clause but
left "preferring lower RTT and lower rate" in its place, so the admitted set
ranked on RTT and rate alone — contradicting this ADR's own Cross-ADR Impact
entry, which states selection uses the same RTT, price, reputation, and
diversity inputs as ADR 001. Cite ADR 001's unified selection score instead
(its own term, defined at ADR 001 § Node Selection Algorithm), which carries
reputation as the graded weight the removal keeps. Citing the formula rather
than paraphrasing it also removes a standing rot vector: the old wording was
already a lossy restatement that silently dropped reputation, wrong against
ADR 001 even before #1456.

The collusive-reporting vector no longer exists. Two rejected-alternative
entries in adr/_history/alternatives-pre-launch.md and one live paragraph in
adr/appendix-blob-cache-eviction.md argued that coupling reputation to
eviction "creates a collusive-reporting vector". That vector was a coalition
sending negative ReputationReport messages to push a competitor below an
eviction threshold — and #1418 deleted ReputationReport, the cdn/reputation/v1
topic, and all cross-node aggregation. Reputation is local-only; no peer can
move another node's score, so the premise is gone. #1418 removed the argument
from appendix-peer-table-eviction.md but missed its two archive compressions
and the parallel claim in appendix-blob-cache-eviction.md, which it never
touched. Drop the clause in all three places, leaving the two rationales the
live appendix still states (conflates discovery with selection; reputation is
noisy in the tail). The rejections themselves are unchanged.

Docs only. Not fixed here: "admissible" at ADR 039 §§ 25/55/116 lost its
definition when #1456 removed the floor it referred to, and the archive's
bare section refs (§1, §3, §4, §6-§11) predate #610 dropping ADR section
numbering — both pre-existing and wider than this change.

Co-Authored-By: Claude Opus 5 <[email protected]>
thiras pushed a commit that referenced this pull request Jul 25, 2026
… vector (#1452)

Rebased onto main after #1456 landed the min-reputation rejection-floor
removal (#1438). The code removal, ADR 001's "graded weight, not a veto"
paragraph, ADR 037's candidate-pool wording, and the CHANGELOG entry are all
already on main and are dropped from this branch. What remains are the stale
reference sites #1456 did not cover, plus one #1418 left behind.

ADR 039 § Source set and selection. The floor was the only path by which
reputation entered multi-source admission. #1456 removed the floor clause but
left "preferring lower RTT and lower rate" in its place, so the admitted set
ranked on RTT and rate alone — contradicting this ADR's own Cross-ADR Impact
entry, which states selection uses the same RTT, price, reputation, and
diversity inputs as ADR 001. Cite ADR 001's unified selection score instead
(its own term, defined at ADR 001 § Node Selection Algorithm), which carries
reputation as the graded weight the removal keeps. Citing the formula rather
than paraphrasing it also removes a standing rot vector: the old wording was
already a lossy restatement that silently dropped reputation, wrong against
ADR 001 even before #1456.

The collusive-reporting vector no longer exists. Two rejected-alternative
entries in adr/_history/alternatives-pre-launch.md and one live paragraph in
adr/appendix-blob-cache-eviction.md argued that coupling reputation to
eviction "creates a collusive-reporting vector". That vector was a coalition
sending negative ReputationReport messages to push a competitor below an
eviction threshold — and #1418 deleted ReputationReport, the cdn/reputation/v1
topic, and all cross-node aggregation. Reputation is local-only; no peer can
move another node's score, so the premise is gone. #1418 removed the argument
from appendix-peer-table-eviction.md but missed its two archive compressions
and the parallel claim in appendix-blob-cache-eviction.md, which it never
touched. Drop the clause in all three places, leaving the two rationales the
live appendix still states (conflates discovery with selection; reputation is
noisy in the tail). The rejections themselves are unchanged.

Docs only. Not fixed here: "admissible" at ADR 039 §§ 25/55/116 lost its
definition when #1456 removed the floor it referred to, and the archive's
bare section refs (§1, §3, §4, §6-§11) predate #610 dropping ADR section
numbering — both pre-existing and wider than this change.

Co-authored-by: Claude Opus 5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant