Rewrite protocol docs: add Relay Chain, Allocator, Mermaid diagrams, …#237
Rewrite protocol docs: add Relay Chain, Allocator, Mermaid diagrams, …#237
Conversation
…and legal language fixes Complete rewrite of the Settlement Protocol documentation section: - Add Relay Chain documentation (Chain ID 537713, Sovereign Stack, Celestia DA) - Add Allocator component docs (MPC chain signatures, Payload Builders) - Restructure from flat component pages to narrative-driven architecture - Add comprehensive flow walkthroughs (Execution, Settlement, Withdrawal, Revert) - Add 8 inline Mermaid sequence diagrams with interactive zoom/pan - Add Design Principles and Security & Audits pages - Add solver and app integration guides - Consolidate contract references and addresses - Separate Vaults as distinct protocol section - Apply legal language fixes (crosschain, revert, destination, asset terminology) - Add 13 URL redirects for old pages - Delete 8 obsolete files Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Visual diagram showing the three chain roles in the protocol (Origin, Relay Chain, Destination) with components, actors, and cost annotations. Uses inline HTML/CSS for full visual control with brand purple styling, dark mode support, and responsive mobile layout. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Move Relay Chain into Components group, add Security Council and MPC Signing pages - Consolidate MPC content back into Allocator page - Create Contracts sidebar group (Addresses, EVM/SVM Depository Reference) - Rewrite Overview with 5 key dimensions (Speed, Cost, Capital Efficiency, Coverage, UX) - Restructure How It Works into Architecture + Flows sections with Mermaid diagrams - Add settlement flow image to Overview - Remove Design page, absorb relevant content into Overview - Update solver guide for direct protocol integration (not API) - Expand Addresses page with Relay Chain and Aurora contract placeholders - Update Security page to link to Security Council component - Clean up cross-references and internal links Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Link to Relay Chain instead of "dedicated low-cost settlement hub" - Remove Info callout, Source Code section, and redundant links from overview - Tighten Failure UX and Coverage copy - Clarify Hub and Allocator both live on Relay Chain in how-it-works Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…awal updates - Oracle reframed as pull-based: never initiates, only responds to requests - Settlement flow: solver requests attestation from Oracle, submits to Hub - Withdrawal flow: solver drives entire flow through Oracle - Add Refund flow: solver-initiated instant refund on origin, settled like a fill - Rename Revert flow to Forced Exit: user-initiated after fill window expires - Add solver abandon concept to shorten forced exit window - Update Oracle component page: request-response pipeline, five attestation types - Change all "revert" terminology to "refund" in user-facing docs - Simplify diagrams: merge Oracle validators/contract, remove NEAR MPC participant Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…eanup - Merge Fast Refund, Slow Refund, and Self Refund flows into the Architecture page - Replace TBD addresses with actual deployed contracts on Relay Chain and Aurora - Link contract addresses to block explorers (explorer.chain.relay.link, explorer.aurora.dev) - Remove bracketed annotations from security page headings Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
New protocol component page documenting the DepositFactory and DepositSweeper contracts that power counterfactual deposit addresses via EIP-1167 minimal proxies. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
clemsos
left a comment
There was a problem hiding this comment.
some small comments but LG !
|
|
||
| ## Overview | ||
|
|
||
| The Allocator is the component responsible for authorizing withdrawals from [Depository](/references/protocol/components/depository) contracts. When a solver wants to claim funds they've earned by filling orders, the Allocator verifies their [Hub](/references/protocol/components/hub) balance and generates a cryptographic proof that the Depository will accept. |
There was a problem hiding this comment.
| The Allocator is the component responsible for authorizing withdrawals from [Depository](/references/protocol/components/depository) contracts. When a solver wants to claim funds they've earned by filling orders, the Allocator verifies their [Hub](/references/protocol/components/hub) balance and generates a cryptographic proof that the Depository will accept. | |
| The Allocator is the component responsible for authorizing withdrawals from [Depository](/references/protocol/components/depository). When a solver wants to claim funds they've earned by filling orders, the Allocator verifies their [Hub](/references/protocol/components/hub) balance and generates a cryptographic proof that the Depository will accept. |
There was a problem hiding this comment.
I think we need a consistent terminology for the two types of depositories. How about "Contract Depository" and "Wallet Depository". We can explain this on the in-depth Depository page, but elsewhere can just use the term "Depository" to describe both
|
Claude encountered an error —— View job I'll analyze this and get back to you. |
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Claude encountered an error —— View job I'll analyze this and get back to you. |
|
Claude encountered an error —— View job I'll analyze this and get back to you. |
…lank line - how-it-works.mdx: Fix "refilled" → "refunded" typo - relay-chain.mdx: Correct Allocator location (Aurora, not Relay Chain) - hub.mdx: Remove duplicate "pattern keeps the Hub simple" sentence - depository.mdx: Add missing blank line before Withdrawals heading Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Claude finished @julien51's task in 2m 23s —— View job Code Review: Protocol Documentation Rewrite
Great progress since the last review — the duplicate text blocks in depository.mdx, oracle.mdx, and hub.mdx are all fixed, Here's what remains: Outstanding Review Feedback Still Not Applied
- **[Hub](/references/protocol/components/hub)** — The ERC6909 multi-token ledger that tracks all balances
- **[Oracle](/references/protocol/components/oracle)** — The contract that processes oracle attestations (mint, burn, transfer)
- **ERC20View** — A wrapper contract that exposes Hub token balances as standard ERC20 tokens for wallet compatibility
Style Issues (per CLAUDE.md)H1 headers in body content — Per docs standards, "No H1 in body content (frontmatter title serves as H1)":
SummaryMost critical issues from the previous review are resolved (duplicate text blocks fixed, refunds.mdx deleted, security.mdx repo names and bounty link corrected, Allocator location clarified). The remaining items are agreed-upon reviewer suggestions that haven't been applied yet — primarily the deposit-addresses contract renaming, security-council table expansion, ERC20View on relay-chain, Sui removal from allocator, Zellic audit addition to depository, and H1→H2 fixes in contract reference pages. |
|
Claude finished @julien51's task in 2m 20s —— View job Code Review: Protocol Documentation Rewrite
Good progress since the last review — several important items have been addressed: Fixed since last review: duplicate text blocks in depository/oracle/hub ✅, Outstanding Review Feedback Still Not AppliedThese are all items that reviewers agreed on but haven't made it into the code yet:
- **ERC20View** — A wrapper contract that exposes Hub token balances as standard ERC20 tokens for wallet compatibility
Should be:
Style Issues (per CLAUDE.md)H1 headers in body content — Per docs standards, "No H1 in body content (frontmatter title serves as H1)":
SummaryMost critical items from earlier reviews are resolved. The remaining items are all agreed-upon reviewer suggestions that haven't been applied yet — 7 items across 7 files. The deposit-addresses contract renaming and security-council table expansion are the largest changes; the rest are single-line fixes. |
- relay-chain.mdx: Add ERC20View to contract list - deposit-addresses.mdx: Rename DepositFactory → DepositAddressFactory, DepositSweeper → DepositAddress, update sweep description - security-council.mdx: Add Update Allocator and Add/Remove Oracle rows, simplify scope section - allocator.mdx: Remove Sui Payload Builder, align diagram step numbers with prose - depository.mdx: Add Zellic to audit list - oracle.mdx: Nuance "never initiates" to reflect withdrawal initiation role - evm-depository.mdx, solana-depository.mdx: Fix H1 → H2 per doc standards Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Claude finished @julien51's task in 1m 28s —— View job Code Review: Protocol Documentation Rewrite
Excellent progress — the vast majority of review feedback has now been applied. Here's the current status: Previously Outstanding Items — Now Fixed
Remaining Items
SummaryNearly all review feedback has been applied — great work. The one outstanding item that @julien51 specifically called out as important is the intent address lookup guidance in |
|
Claude finished @julien51's task in 2m 1s —— View job Code Review: Protocol Documentation Rewrite
Nearly all feedback from previous reviews has been applied — excellent work. Here's the current status: Previously Flagged Items — All Fixed
One Outstanding Item
The current text (lines 52-58) mentions the Explorer and uses Minor Nits
SummaryThe PR is in great shape. The only outstanding item that @julien51 specifically called out as important is the intent address lookup guidance in |
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Claude finished @julien51's task in 2m 23s —— View job Code Review: Protocol Documentation Rewrite
Excellent work — this is a major improvement over the previous flat structure. The narrative-driven architecture with component pages, Mermaid sequence diagrams, and clear flow walkthroughs is well-organized and thorough. Nearly all previous review feedback has been addressed. Previously Flagged Items — StatusAll critical items from prior reviews are resolved:
One Outstanding Item
Lines 60-80 describe the order address derivation (from chainId, depositor, timestamp, depositId), which is a different concept. The intent address derivation from Minor Nits
SummaryThe PR is in great shape. The only outstanding item from reviewer feedback is the intent address guidance in |
|
Claude finished @ptrwtts's task in 1m 36s —— View job Code Review: Protocol Documentation Rewrite
Excellent progress — nearly all review feedback from @julien51, @clemsos, and @ptrwtts has been applied. The documentation quality, structure, and Mermaid diagrams are in great shape. Previously Flagged Items — All Fixed
One Outstanding Item
The current text (lines 52-58) mentions the Explorer and uses Minor Nits (can be follow-up)
SummaryThe PR is in great shape — all critical and nearly all outstanding review items have been addressed. The only remaining item that @julien51 specifically called out as important is the intent address lookup guidance in |
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Claude finished @julien51's task in 1m 57s —— View job Code Review: Protocol Documentation Rewrite
The PR is in excellent shape. All critical issues from previous reviews have been resolved. Here's the full status: All Previously Flagged Issues — Resolved
Remaining Minor ItemsThese are non-blocking observations:
SummaryThe PR is ready to merge. All critical issues, duplicate text blocks, and agreed-upon reviewer suggestions have been applied. The documentation quality, narrative structure, Mermaid diagrams, and cross-linking are excellent throughout. The only remaining items are two minor "sweeper" → "DepositAddress" terminology leftovers in |
Complete rewrite of the Settlement Protocol documentation section: