Repository navigation
docs(adr): add README preamble + thematic reading order (Tier 1) - #347
Merged
Merged
Conversation
Closes #344. Adds `adr/README.md` as the protocol's preamble — what deCDN is, the six core design principles, the canonical 32-term glossary (grouped into wire/payments/tokenomics/enforcement), and pointers into the reading order. GitHub auto-renders this when navigating to `/adr/`, making it the natural entry point. Adds a **Reading Order** section to `architecture.md` that groups the 32 ADRs into 8 thematic chapters, each assuming the previous chapters are read: 1. Foundations (000, 001, 002, 005) 2. Discovery (022, 015) 3. Payments (003, 010, 012, 024) 4. Tokenomics & incentives (026, 027, 018, 028, 029, 030, 031, 032) 5. Verification & enforcement (014, 007, 008, 011) 6. Governance & contracts (009, 016) 7. Operations (019, 020, 023, 025) 8. Supporting infrastructure (021, 013, 017, 006) The numeric per-ADR index below stays as the canonical reference; this section is the first-time-reader path. Consolidates the partial Glossary previously in `architecture.md` into the README's expanded version (32 terms vs the prior 11), and leaves a one-line pointer at the old location. Tier 1 of the book-readiness program; #345 (smooth narrative connectives + cross-cutting lifts) and #346 (move alternatives to adr/_history/) are queued behind this. Tier 1 was the lowest-risk, highest-leverage move — does not touch any individual ADR body.
There was a problem hiding this comment.
Code Review
This pull request establishes a comprehensive protocol specification for deCDN. It introduces a new adr/README.md containing core design principles, a thematic reading order for Architecture Decision Records (ADRs), and a categorized glossary. Additionally, adr/architecture.md is updated to include the thematic reading order and to reference the README for the canonical glossary. Review feedback focuses on improving documentation accuracy and compatibility, specifically by refining ADR cross-references for Merkle proofs, replacing non-standard characters in mathematical formulas for better rendering, and correcting the scaling logic for challenge bonds between PoC and production environments.
2 of 3 comments addressed (1 wontfix). README.md:40 — Chunk glossary entry now cross-refs both ADR 002 (the addressing scheme) and ADR 014 (the slash-evidence verification flow). Gemini was right that ADR 014 is the canonical home for the verification logic; ADR 002 still owns the addressing scheme itself, so the entry now links both. README.md:65 — `working_bytes` formula now uses `*` for multiplication instead of `·` (middle dot). The middle dot is fine in most renderers but `*` is universally compatible across viewers and copy-paste-friendly into pseudocode contexts. Backticks kept (formula vs prose distinction). README.md:80 — wontfix. Gemini suggested the challenge-bond values (100 PoC / 50 production) were reversed because production bonds are "typically" higher than PoC. They aren't reversed: PoC TOKEN is freely-mintable testnet supply (no market value, so 100 TOKEN is essentially free), while production TOKEN is the fixed-supply (1B) canonical asset with real market value (so 50 TOKEN is the higher economic deterrent). Confirmed against the canonical values across ADRs 011, 014, and 023. Em-dash → semicolon suggestions across all three comments are also declined: em-dashes in *prose* (table cells, glossary entries) don't affect GFM anchors. Only em-dashes in *headings* produce the `--` double-hyphen anchor pattern, and #343 already standardized those to the actual GFM-generated form. Glossary prose stays.
Same-structure principle ("PoC and Prod follow the same structure;
fee router is the only thing that changes") applied to the challenge
bond. The historical 100 PoC / 50 production split was rationalized
by "PoC TOKEN has no market value, so the higher nominal makes a
deterrent" — but that's exactly the kind of nominal-vs-real-value
split that creates implementer confusion. Unify to 100 TOKEN.
Touched:
- README.md glossary entry
- ADR 005:83 — wire-protocol cross-ref to challenge-bond requirement
- ADR 011:207 — blacklist-violation slashing path
- ADR 016:151 — SlashJudge constructor parameters table
- ADR 023:23, :120 — PoC/Prod comparison tables (both columns now 100)
- ADR 023:182 — `challenge_bond_token` constants table
Programmatic check: zero `50 TOKEN` mentions remain in the ADR set.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #344.
What
Two additions:
adr/README.md— protocol preamble. GitHub auto-renders this when navigating to/adr/, so it doubles as the natural entry point.architecture.md— 32 ADRs organized into 8 thematic chapters, ordered for top-to-bottom reading.README.md contents
architecture.mdand adds tokenomics terms)architecture.mdadr/_history/)Reading order
The numeric per-ADR index below stays as the canonical reference; this section is the first-time-reader path. All 32 ADRs are covered exactly once.
Out of scope
Alternatives Consideredsections toadr/_history/— that's ADR book-readiness Tier 3: strip decision-record scaffolding, move to adr/_history/ #346 (Tier 3).Test plan
https://github.com/decdn/decdn/tree/main/adrafter merge rendersREADME.mdautomatically.architecture.mdGlossary now points to README rather than carrying its own (partial) copy.README.md→ reading order → individual ADRs without backtracking.🤖 Generated with Claude Code