ACDC_UI_UX_Specification_v1.0.cspec
1 # AC|DC NETWORK 2 # UI/UX SPECIFICATION 3 4 **Version:** 1.0 5 **Date:** January 14, 2027 6 **Status:** Complete — Ready for Implementation 7 8 **Brand:** AC|DC Network (Alpha Chain | Delta Chain) 9 **Domain:** ac-dc.network 10 11 --- 12 13 # PART I: ARCHITECTURE OVERVIEW 14 15 ## Product Segmentation 16 17 **Model:** Hub-and-Spoke 18 19 - Hub: Central identity, wallet, and state management layer 20 - Spokes: Specialized applications for role-specific workflows 21 - Unified authentication and wallet-core across all contexts 22 23 --- 24 25 # PART II: IDENTITY & WALLET ARCHITECTURE 26 27 ## Identity Model 28 29 **Approach:** Wallet-First with Paynym-Style Root Credentials 30 31 - Single BIP39 mnemonic as root 32 - Multi-curve derivation for cross-chain support 33 - Disposable stealth addresses per transaction 34 - ENS-style name service integration 35 36 ## Multi-Curve Derivation 37 38 **Root Seed derives all chains:** 39 40 ``` 41 BIP39 Mnemonic (Single Backup Phrase) 42 ├── BLS12-377 Domain (ALPHA/DELTA Native) 43 │ └── Payment Code: acdc1qxp72k9... (Aleo-native format) 44 │ 45 ├── secp256k1 Domain (BTC/ETH) 46 │ └── Payment Code: PM8TJS2JxQ5zt... (BIP47 format) 47 │ 48 └── ed25519 Domain (SOL) 49 └── Standard Solana derivation 50 ``` 51 52 ## Derivation Path Structure 53 54 **Format:** BIP47 Purpose-Based (Option B) 55 56 ``` 57 m / 47' / [BLOX]' / account' / class' / index 58 59 Address Classes: 60 ├── 0' → ALPHA private addresses 61 ├── 1' → DELTA trading addresses (public) 62 ├── 2' → DELTA DX address (private) 63 └── 3' → Reserved (future) 64 ``` 65 66 ## Payment Code Format 67 68 **Aleo-Native Format:** 69 70 ``` 71 Payment Code Structure: 72 ├── Version (1 byte): 0x01 73 ├── Features (1 byte): Bitfield for address classes 74 ├── View Key Component (32 bytes) 75 ├── Spend Key Component (32 bytes) 76 ├── Diversifier (11 bytes) 77 └── Checksum (4 bytes): Blake2s truncated 78 79 Encoding: Bech32m with "acdc1" HRP 80 Example: acdc1qxp72k9wd5clhm8yvqtnjfk4zqwqglz8v7qwc5r... 81 ``` 82 83 ## Stealth Address Implementation 84 85 **Approach:** Native Integration with Aleo Primitives 86 87 - Leverage Aleo's built-in record encryption 88 - BIP47-style payment code layer on top 89 - Root credential = extended viewing key 90 - Disposable addresses derived from root 91 92 --- 93 94 # PART III: NAME SERVICE 95 96 ## Namespace Structure 97 98 **Model:** Dual-Tier (Flat Personal + Reserved Institutional) 99 100 ``` 101 Personal (flat): 102 ├── alice.blox 103 ├── bob.blox 104 └── User-controlled, first-come-first-served 105 106 Institutional (reserved prefixes): 107 ├── gov.*.blox → Central Bank Governors 108 ├── val.*.blox → Validators 109 └── sys.*.blox → System services 110 ``` 111 112 ## Registration Pricing 113 114 **Model:** Vickrey Auction for Premium + Fixed for Standard 115 116 ``` 117 Premium Names (3-4 chars, dictionary words): 118 ├── Sealed-bid second-price auction 119 ├── 7-day auction window 120 ├── Annual renewal: 10% of winning bid 121 122 Standard Names (5+ chars, non-dictionary): 123 ├── Fixed fee: 10 ALPHA/year 124 └── Instant registration 125 ``` 126 127 ## Revenue Flow 128 129 ``` 130 All name service revenue → DELTA Revenue Pool 131 ├── Validators/Provers 132 ├── Treasury/Insurance 133 └── DX Holders 134 ``` 135 136 ## Governance 137 138 | Action | Required Approval | 139 |--------|-------------------| 140 | Modify pricing model | DELTA governance (67%+) | 141 | Modify premium word list | DELTA governance (67%+) | 142 | Add new HLD (e.g., .trade) | Joint: ALPHA (67%) + DELTA (67%) | 143 | Allocate institutional subnames | ALPHA Governors only | 144 145 ## Name Service Resolution 146 147 ``` 148 name.blox → { 149 primary: "acdc1qxp72k9...", // ALPHA/DELTA (default) 150 btc: "PM8TJS2JxQ5zt...", // Bitcoin 151 eth: "0x742d35Cc...", // Ethereum 152 sol: "7EcDhSYGxXys..." // Solana 153 } 154 ``` 155 156 ## Name Service Extended Functions 157 158 ``` 159 1. IDENTITY RESOLUTION 160 └── name → payment codes (all supported chains) 161 162 2. ENCRYPTED MESSAGE DROP 163 ├── Swap code delivery 164 ├── Payment requests 165 └── Wallet-to-wallet notifications 166 167 3. METADATA (optional, user-controlled) 168 ├── Display name 169 ├── Avatar/icon 170 └── Public contact preferences 171 ``` 172 173 --- 174 175 # PART IV: WALLET RECOVERY 176 177 ## Recovery Methods 178 179 **All users must have seed phrase; additional methods optional:** 180 181 | Method | Description | Requirement | 182 |--------|-------------|-------------| 183 | Seed Phrase | BIP39 mnemonic (24 words) | Mandatory | 184 | Social Recovery | Guardian threshold + timelock | Optional | 185 | Shamir Backup | K-of-N secret sharing (SLIP-39) | Optional | 186 187 ## Social Recovery Specification 188 189 ``` 190 Setup: 191 ├── Designate 3-7 guardians (wallet addresses) 192 ├── Set threshold (e.g., 3-of-5) 193 └── Register on-chain (DELTA) 194 195 Recovery Process: 196 ├── User initiates recovery to new payment code 197 ├── Guardians submit approval signatures 198 ├── Threshold met → 7-day timelock begins 199 ├── Original owner can cancel during timelock 200 └── After timelock: name service + DX address repoint 201 202 Constraints: 203 ├── Guardian changes require 7-day timelock 204 ├── Cannot remove all guardians while recovery in progress 205 └── Guardians cannot initiate (only approve) 206 ``` 207 208 ## Shamir Backup Specification 209 210 ``` 211 Setup: 212 ├── SLIP-39 standard 213 ├── Default: 5 shares, 3 required (configurable) 214 └── User distributes shares 215 216 Recovery: 217 ├── Gather K shares 218 ├── Reconstruct seed locally 219 └── Full wallet restoration (no on-chain interaction) 220 ``` 221 222 --- 223 224 # PART V: 2FA & DEVICE MESH 225 226 ## Security Model 227 228 **Tier 1 Platforms (Secure Enclave Available):** 229 - iOS, Android, macOS (Apple Silicon/T2) 230 - 2FA: Optional (enclave provides hardware binding) 231 232 **Tier 2 Platforms (No Reliable Enclave):** 233 - Windows, Linux, Web, CLI 234 - 2FA: Mandatory for signing operations 235 236 ## Supported 2FA Methods 237 238 | Method | Security Level | Notes | 239 |--------|---------------|-------| 240 | Device Mesh (Mobile) | High | Recommended default | 241 | Hardware FIDO2 | Highest | YubiKey, Titan, etc. | 242 | TOTP | Moderate | Warned as less optimal | 243 244 **Must enable at least one method.** 245 246 ## Device Mesh Architecture 247 248 ``` 249 Wallet Seed 250 └── Device Mesh Root Key 251 └── Per-Device Authenticator Keys 252 ├── Device A (primary mobile) 253 ├── Device B (backup mobile) 254 └── Device C (tablet) 255 256 Features: 257 ├── Multiple devices registered to one wallet 258 ├── Any device can approve transactions 259 ├── Backup devices if primary lost 260 └── Fully self-sovereign (no platform sync) 261 ``` 262 263 ## Device Mesh Operations 264 265 ``` 266 Add Device: 267 ├── Existing device displays pairing QR 268 ├── New device scans QR 269 ├── Local key exchange completes 270 └── Both devices update local device list 271 Requirement: Physical proximity 272 273 Remove Device: 274 ├── Any active device initiates removal 275 ├── Signs removal message 276 ├── Propagates via next QR sync 277 └── Minimum 1 device required 278 279 Encrypted Backup: 280 ├── Export mesh config encrypted with seed + passphrase 281 ├── Store on USB, paper QR, etc. 282 └── Restore on new device with seed + backup 283 ``` 284 285 ## Transaction Approval Communication 286 287 **Methods (user configures preference):** 288 289 | Method | Security | Convenience | Default | 290 |--------|----------|-------------|---------| 291 | QR Air-Gap | Highest | Lower | Yes | 292 | Local Network | High | Higher | Opt-in | 293 | Bluetooth LE | High | Higher | Opt-in | 294 295 **High-value override:** Always require QR above threshold. 296 297 --- 298 299 # PART VI: PLATFORM ARCHITECTURE 300 301 ## Technical Stack 302 303 **Model:** Rust Core + Platform Shells 304 305 ``` 306 Core (Rust Library - wallet-core): 307 ├── Key derivation (BIP39 → multi-curve) 308 ├── Payment code generation/parsing 309 ├── Address derivation (all classes) 310 ├── Transaction construction 311 ├── Proof generation (via snarkVM bindings) 312 ├── Signing operations 313 ├── Shamir share generation/reconstruction 314 └── Social recovery state management 315 316 Platform Shells: 317 ├── iOS: Swift + Rust FFI 318 ├── Android: Kotlin + Rust FFI 319 ├── macOS/Windows/Linux: Tauri (Rust-native) 320 ├── Web: Rust → WASM 321 └── CLI: Rust-native 322 ``` 323 324 ## Security Classification 325 326 | Platform | Secure Enclave | 2FA Requirement | 327 |----------|----------------|-----------------| 328 | iOS | Yes | Optional | 329 | Android | Yes (StrongBox) | Optional | 330 | macOS | Yes | Optional | 331 | Windows | Limited (TPM) | Mandatory | 332 | Linux | Limited (TPM) | Mandatory | 333 | Web | No | Mandatory | 334 | CLI | No | Mandatory | 335 336 --- 337 338 # PART VII: TOKEN MODEL 339 340 ## Chain Tokens 341 342 ``` 343 ALPHA Chain: 344 └── ALPHA: Native token, privacy-preserving 345 346 DELTA Chain: 347 ├── DELTA (DX): Governance token, privately held, rarely traded 348 └── sAX (Synthetic Alpha): Trading token, public balances 349 ``` 350 351 ## ALPHA ↔ sAX Relationship 352 353 **Model:** True Synthetic (Collateralized) 354 355 ``` 356 Mechanism: 357 ├── User locks ALPHA in shielded escrow contract 358 ├── sAX minted 1:1 on DELTA chain 359 ├── sAX is claim on escrowed ALPHA 360 └── Redeem: burn sAX, release ALPHA 361 362 Properties: 363 ├── ALPHA never leaves ALPHA chain 364 ├── sAX supply always matches locked ALPHA 365 ├── Cross-chain attestation verifies collateral 366 └── Block-speed operations (same process memory) 367 ``` 368 369 ## DX Staking Model 370 371 ``` 372 DEFAULT STATE: Staked 373 ├── New DX acquired is staked by default 374 ├── Earns dividends 375 ├── Eligible for governance (if ≥10,000) 376 └── Subject to non-participation slashing (if ≥10,000) 377 378 UNSTAKED DX: 379 ├── No dividends 380 ├── No voting rights 381 ├── No slashing risk 382 └── Freely transferable 383 384 TIMING: 385 ├── Unstaking: 1 epoch (1 day) cooldown 386 ├── Restaking: 5 epochs (5 days) warmup 387 └── Validators: Cannot unstake without losing slot 388 ``` 389 390 --- 391 392 # PART VIII: UNIFIED WALLET 393 394 ## Multi-Account Model 395 396 ``` 397 UNIFIED WALLET APP 398 ├── Account 1: "Personal" 399 │ ├── Seed A (isolated) 400 │ └── Features based on role detection 401 │ 402 ├── Account 2: "Validator Operations" 403 │ ├── Seed B (isolated) 404 │ └── Shows Validator Dashboard 405 │ 406 ├── Account 3: "Prover Farm" 407 │ ├── Seed C (isolated) 408 │ └── Shows Prover Dashboard 409 │ 410 └── Account 4: "Trading LLC" 411 ├── Seed D (isolated) 412 └── Shows Trading + Governance 413 414 SANDBOXING: 415 ├── Each seed tree fully isolated 416 ├── No cross-account key access 417 ├── Separate device mesh per account (optional) 418 └── Clear visual distinction between accounts 419 ``` 420 421 ## Wallet Structure (Three Pockets) 422 423 ``` 424 ┌─────────────────────────────────────────────────────────────────┐ 425 │ 🔒 ALPHA (Private) │ 426 │ Privacy-preserving currency │ 427 │ [Send] [Receive] [Mint sAX →] │ 428 ├─────────────────────────────────────────────────────────────────┤ 429 │ 🔒 DELTA DX (Private) │ 430 │ Governance token (rarely traded) │ 431 │ [Vote] [Stake] │ 432 ├─────────────────────────────────────────────────────────────────┤ 433 │ 👁 sAX Trading (Public) │ 434 │ Collateralized by locked ALPHA │ 435 │ [Trade] [← Redeem] [Off-Ramp] │ 436 ├─────────────────────────────────────────────────────────────────┤ 437 │ 🔗 External Chains │ 438 │ BTC, ETH, SOL, TRX + tokens (USDT, etc.) │ 439 │ [Send] [Receive] [Swap to ALPHA ⇄] │ 440 ├─────────────────────────────────────────────────────────────────┤ 441 │ 📥 Imported Wallets (Device-Local Only) │ 442 │ NOT synced, NOT recoverable from ecosystem seed │ 443 │ [Sweep to Ecosystem →] │ 444 └─────────────────────────────────────────────────────────────────┘ 445 ``` 446 447 ## External Chain Support 448 449 **Scope:** Full send/receive for major L1s and subtokens 450 451 ``` 452 Ecosystem Keys (from Paynym Seed): 453 ├── Synced across device mesh 454 ├── Recoverable via seed/Shamir/social 455 └── Backed by name service 456 457 Imported Keys (Device-Local Only): 458 ├── NOT synced 459 ├── NOT recoverable from ecosystem seed 460 ├── User maintains separate backup 461 └── Sources: seed phrases, private keys, keystores, hardware wallets 462 ``` 463 464 ## Conditional Features 465 466 ``` 467 IF (account.addresses.any IS validator) { 468 show_validator_tab = true 469 } 470 471 IF (account.addresses.any IS prover) { 472 show_prover_tab = true 473 } 474 475 IF (account.dx_staked >= GOVERNANCE_THRESHOLD) { 476 show_governance_tab = true 477 } 478 ``` 479 480 --- 481 482 # PART IX: TRADING INTERFACE 483 484 ## Interface Modes 485 486 **Model:** Tiered (Simple Default, Pro Mode Toggle) 487 488 ``` 489 Simple Mode (default): 490 ├── Market buy/sell 491 ├── Basic limit orders 492 ├── Simple position view 493 └── Basic charts 494 495 Pro Mode (toggle): 496 ├── All order types 497 ├── TradingView-style charting 498 ├── Depth of market 499 ├── Position analytics 500 ├── Hotkeys 501 └── API access 502 ``` 503 504 ## Market Maker Mode 505 506 **Integrated into Trading Interface (not separate console)** 507 508 ``` 509 Anyone with balance can provide liquidity: 510 ├── No registration required 511 ├── No backend infrastructure 512 └── Just post orders on orderbook 513 514 MM Mode Features: 515 ├── Quick Quote (bid + ask simultaneously) 516 ├── Bulk order management 517 ├── Inventory tracking 518 ├── Revenue analytics 519 └── Cross-chain balance view 520 ``` 521 522 ## Trading Pairs 523 524 ``` 525 BASKET CURRENCIES (Always Available): 526 ├── Top 20 floating currencies 527 ├── XAU (Gold) 528 └── Components of ALPHA valuation algorithm 529 530 GOVERNOR CURRENCIES: 531 └── Auto-added on Governor admission 532 533 CRYPTO: 534 ├── BTC (at launch) 535 └── Additional via DELTA governance 536 537 ALL PAIRS: 538 ├── Quoted as ASSET/AX 539 ├── Settled in sAX 540 ├── Margin in sAX 541 └── P&L in sAX 542 ``` 543 544 ## ALPHA Valuation Algorithm 545 546 ``` 547 Status: Set at Genesis 548 549 CHANGE REQUIREMENTS: 550 ├── ALPHA Governors: 67% approval 551 ├── DELTA Governance: 51% approval 552 ├── Joint approval required 553 └── Implementation delay: 3 months 554 555 Delay Purpose: 556 ├── Allow position adjustments 557 ├── Allow Governor rebalancing 558 └── Market price discovery 559 ``` 560 561 --- 562 563 # PART X: P2P SWAP SYSTEM 564 565 ## Architecture 566 567 **Model:** Pure P2P with Adaptor Signatures 568 569 ``` 570 DEX Role (Orderbook Only): 571 ├── Advertise orders 572 ├── Match counterparties 573 ├── Facilitate communication 574 ├── Track reputation 575 └── NO custody, NO escrow, NO key control 576 577 Swap Security: 578 ├── Adaptor signatures (atomic, no escrow) 579 ├── Zero counterparty risk (math guarantees) 580 └── Stealth addresses hide both parties 581 ``` 582 583 ## Swap Modes 584 585 ``` 586 1. PUBLIC ORDERBOOK 587 └── Orders visible to all, anyone can take 588 589 2. PRIVATE SWAP CODE 590 ├── Order NOT posted to orderbook 591 ├── Generates unique shareable code 592 └── Only code holder can take 593 594 3. DIRECT WALLET-TO-WALLET 595 └── No DEX involvement at all 596 ``` 597 598 ## Private Swap Code 599 600 ``` 601 Format: swap1[bech32m encoded payload] 602 603 Payload: 604 ├── Swap ID, maker address 605 ├── Offering/requesting assets and amounts 606 ├── Expiry timestamp 607 ├── Maker adaptor pubkey 608 └── Checksum 609 610 Delivery: 611 ├── Name service messaging (primary for named users) 612 └── Manual sharing (copy, QR, external channels) 613 ``` 614 615 ## Griefing Protection 616 617 **Model:** Reputation + Voluntary Bonds 618 619 ``` 620 Reputation System: 621 ├── DEX tracks completion rate per address 622 ├── Displayed to counterparties 623 └── Filter orders by minimum reputation 624 625 Voluntary Bonds: 626 ├── Order poster can attach sAX bond 627 ├── If poster griefs: bond forfeited 628 └── Higher bond = more attractive order 629 630 Neither is mandatory—pure P2P always possible. 631 ``` 632 633 ## DELTA Trading Privacy Model 634 635 ``` 636 ENCRYPTED (Private): 637 ├── Mempool (no front-running) 638 ├── External chain addresses 639 ├── ALPHA addresses 640 ├── DX addresses 641 └── Trading address ↔ identity linkage 642 643 TRANSPARENT (Public): 644 ├── DELTA trading addresses 645 ├── Orderbook 646 ├── Trade execution history 647 └── Position data 648 649 ADDRESS ROTATION: 650 └── Fresh trading address on each withdrawal to ALPHA 651 ``` 652 653 --- 654 655 # PART XI: FIAT OFF-RAMP 656 657 ## Architecture 658 659 **On-Ramps:** P2P swap only (no fiat in ecosystem) 660 661 **Off-Ramps:** Governor-operated with external KYC 662 663 ``` 664 DATA BOUNDARIES: 665 666 Ecosystem knows: 667 ├── User's trading address 668 ├── ID Code (opaque string) 669 ├── ID Code validity status 670 └── Off-ramp transaction history 671 672 Governor knows: 673 ├── User's legal identity (KYC) 674 ├── User's bank account 675 ├── ID Code ↔ Identity mapping 676 └── Compliance records 677 678 NEVER SHARED: 679 ├── KYC data never enters ecosystem 680 ├── Bank details never enter ecosystem 681 └── Governor data never shared between Governors 682 ``` 683 684 ## User Flow 685 686 ``` 687 First Time: 688 1. User selects jurisdiction (Governor) 689 2. Redirected to Governor's external KYC portal 690 3. Completes KYC + provides bank account 691 4. Receives ID Code 692 5. Returns to ecosystem, enters ID Code 693 6. System verifies against Governor whitelist 694 7. Registration complete 695 696 Returning User: 697 1. User initiates off-ramp 698 2. System checks ID Code validity 699 3. If valid: shows rate, amount input 700 4. User confirms 701 5. Automated settlement (T+3) 702 ``` 703 704 --- 705 706 # PART XII: GOVERNANCE 707 708 ## Structure 709 710 ``` 711 ALPHA GOVERNORS: 712 ├── Vote on ALPHA proposals 713 ├── Vote on DELTA proposals (automatic DX governance) 714 ├── Vote on Joint proposals 715 └── Interface: Governor Console 716 717 DELTA HOLDERS (Qualified ≥10,000 DX staked): 718 ├── Vote on DELTA proposals only 719 ├── Non-participation = slashing 720 └── Interface: Unified Wallet (embedded) 721 722 DELTA HOLDERS (Unqualified): 723 └── No voting rights, no governance UI 724 ``` 725 726 ## DX Governance Visibility 727 728 ``` 729 IF (user.dx_staked >= GOVERNANCE_THRESHOLD) { 730 show_governance_tab = true 731 show_active_proposals = true 732 show_voting_interface = true 733 show_slashing_warnings = true 734 } ELSE { 735 show_governance_tab = false 736 } 737 ``` 738 739 ## Slashing Penalties 740 741 | Proposal Type | Penalty | 742 |---------------|---------| 743 | Standard | 1% of staked DX | 744 | Emergency Stop | 10% of staked DX | 745 | Emergency Resume | 10% of staked DX | 746 747 ## Notifications 748 749 ``` 750 CORE WALLET (Required): 751 ├── In-app badge/banner 752 ├── Push notifications (mobile) 753 └── User responsibility to check ≥ once per 24h 754 755 NAME SERVICE MESSENGER (Separate App, Optional): 756 ├── Runs as independent process 757 ├── Monitors message drops 758 ├── Triggers immediate alarms 759 ├── Security-isolated from wallet keys 760 └── Extensible for external relay (email, Telegram, webhook) 761 ``` 762 763 --- 764 765 # PART XIII: APPLICATION INVENTORY 766 767 ## Hub + Core Spokes (Single App) 768 769 | Spoke | Description | 770 |-------|-------------| 771 | Unified Wallet | All assets, three pockets | 772 | Trading Terminal | DEX, perpetuals, P2P swaps, MM mode | 773 | Name Service Manager | Register, manage, resolve | 774 | Governance | DELTA voting (if qualified) | 775 | Validator Dashboard | Status & rewards (if validator) | 776 | Prover Dashboard | Status & rewards (if prover) | 777 778 ## Governor Console (Separate Web/App) 779 780 ``` 781 Minimal, "Easy Button" aesthetic 782 783 Functions: 784 ├── Minting (to operational wallets) 785 ├── Internal governance (multisig, delegates) 786 ├── Whitelist management 787 ├── API integrations (KYC, banking, webhooks) 788 ├── Proposal creation and voting 789 └── Status (read-only, also on ALPHA-Scanner) 790 ``` 791 792 ## Public Utilities (Web) 793 794 | Tool | Description | 795 |------|-------------| 796 | ALPHA-Scanner | Block explorer, Governor transparency | 797 | Oracle Monitor | Integrated into ALPHA-Scanner + API | 798 | Developer Portal | API docs, SDK, testnet faucet | 799 800 ## Validator/Prover Interfaces 801 802 ``` 803 PRIMARY (Required): 804 ├── CLI Tools (full management) 805 ├── API (REST + WebSocket) 806 └── Rich documentation 807 808 SECONDARY (Convenience): 809 └── Graphical dashboard in Unified Wallet 810 ``` 811 812 --- 813 814 # PART XIV: ALPHA-SCANNER 815 816 ## Modes 817 818 **Model:** Tiered (Dashboard Default, Explorer Toggle) 819 820 ``` 821 Dashboard Mode: 822 ├── Clean metrics and visualizations 823 ├── Key stats prominent 824 ├── Governor transparency charts 825 └── Accessible to non-technical users 826 827 Explorer Mode: 828 ├── Raw block/transaction data 829 ├── Technical detail 830 ├── Full search capability 831 └── For developers and power users 832 ``` 833 834 ## Required Sections 835 836 ``` 837 ├── Network Status 838 ├── Governor Transparency 839 │ ├── Outstanding Balances 840 │ ├── Mint/Burn History 841 │ └── Governance Participation 842 ├── Validator Status 843 ├── Prover Status 844 ├── Governance Activity 845 ├── Oracle Rates + Health 846 └── Cross-Chain Health Index 847 ``` 848 849 ## Deployment 850 851 ``` 852 ├── Canonical instance (ecosystem-operated) 853 └── Governor mirrors (each Governor ≥1) 854 ├── Localized language (national language) 855 ├── Public API access 856 └── Data retention: 52-364 epochs 857 858 Update Frequency: Every 5 minutes 859 ``` 860 861 ## Oracle Monitor 862 863 **Integrated into ALPHA-Scanner + Standalone API** 864 865 ``` 866 UI (ALPHA-Scanner section): 867 ├── Current rates 868 ├── Oracle health 869 ├── Historical rates 870 └── Deviation alerts 871 872 API (programmatic access): 873 ├── Real-time rate feeds 874 ├── Multi-oracle comparison 875 └── Failover status 876 ``` 877 878 --- 879 880 # PART XV: DEVELOPER PORTAL 881 882 ## Architecture 883 884 **Model:** Phased (Docs First, Interactive Later) + Radicle Integration 885 886 ``` 887 PHILOSOPHY: 888 ├── Documentation-as-code (lives in repos) 889 ├── Community-governed via Radicle 890 ├── Changes via pull requests + governance 891 └── Decentralized hosting (mirrors encouraged) 892 893 PHASE 1 (MVP): 894 ├── Static site generated from repo 895 ├── API reference (OpenAPI spec) 896 ├── SDK docs (Rust, TypeScript, Python) 897 ├── Tutorials/guides (markdown) 898 ├── Code examples (runnable) 899 └── Testnet faucet (simple) 900 901 PHASE 2 (Post-Launch): 902 ├── Interactive API sandbox 903 ├── API key management 904 ├── Usage dashboard 905 └── Community contributions dashboard 906 ``` 907 908 ## Repository Structure 909 910 ``` 911 alpha-delta-docs/ 912 ├── api/ # OpenAPI specs 913 ├── sdk/ # SDK documentation per language 914 ├── guides/ # Integration guides 915 ├── tutorials/ # Step-by-step tutorials 916 ├── reference/ # Technical reference 917 ├── cli/ # CLI documentation 918 ├── concepts/ # Conceptual explanations 919 ├── i18n/ # Translations 920 └── tools/ # Build/validation tools 921 ``` 922 923 --- 924 925 # PART XVI: ONBOARDING 926 927 ## Model 928 929 **Approach:** Quick Start + Progressive Setup with Persistent Nagging 930 931 ``` 932 INITIAL SETUP (Required, ~2 minutes): 933 ├── Create seed phrase (24 words) 934 ├── Verify seed phrase 935 └── Done → Wallet home 936 937 PROGRESSIVE PROMPTS (Persistent until complete): 938 ├── Device mesh setup 939 ├── Recovery method (Social or Shamir) 940 ├── Name registration 941 └── Persona selection 942 943 NAG BEHAVIOR: 944 ├── Semi-obtrusive banner (cannot permanently dismiss) 945 ├── Escalates over time 946 ├── Contextual triggers (balance thresholds) 947 └── Disappears only when setup complete 948 ``` 949 950 ## Personas 951 952 ``` 953 PERSONAL: 954 ├── Simple mode default 955 ├── Privacy-focused prompts 956 └── Friendly, non-technical tone 957 958 TRADER: 959 ├── Pro mode default 960 ├── MM mode visible 961 └── Professional, data-focused tone 962 963 OPERATOR: 964 ├── Validator/Prover tabs prominent 965 ├── CLI docs linked 966 └── Technical, operational tone 967 968 DEVELOPER: 969 ├── Testnet toggle in header 970 ├── Developer Portal linked 971 └── Technical, code-focused tone 972 ``` 973 974 --- 975 976 # PART XVII: LOCALIZATION 977 978 ## Architecture 979 980 **Model:** Multilingual from Day One with AI-Generated Initial Translations 981 982 ``` 983 LAUNCH LANGUAGES (Top 20 by speakers): 984 ├── English (en) - Source 985 ├── Mandarin Chinese (zh-CN) 986 ├── Hindi (hi) 987 ├── Spanish (es) 988 ├── French (fr) 989 ├── Arabic (ar) - RTL 990 ├── Bengali (bn) 991 ├── Portuguese (pt) 992 ├── Russian (ru) 993 ├── Japanese (ja) 994 ├── Indonesian (id) 995 ├── German (de) 996 ├── Korean (ko) 997 ├── Turkish (tr) 998 ├── Vietnamese (vi) 999 ├── Italian (it) 1000 ├── Thai (th) 1001 ├── Polish (pl) 1002 ├── Dutch (nl) 1003 └── Hebrew (he) - RTL 1004 ``` 1005 1006 ## Resource File Structure 1007 1008 ```json 1009 { 1010 "key": "unique.string.identifier", 1011 "source": "English text", 1012 "context": "Where/how this string is used", 1013 "max_length": null | number, 1014 "placeholders": ["list", "of", "variables"], 1015 "translations": { 1016 "zh-CN": { "text": "中文文本", "status": "ai|reviewed|certified" } 1017 } 1018 } 1019 ``` 1020 1021 ## Layout Adaptation 1022 1023 ``` 1024 RTL Languages (Arabic, Hebrew): 1025 ├── Mirror entire layout horizontally 1026 ├── Navigation: right side 1027 ├── Text alignment: right 1028 └── Numbers: remain LTR 1029 1030 Vertical Languages (Japanese, Chinese): 1031 ├── Support vertical text blocks (optional) 1032 └── User preference setting 1033 1034 Text Expansion: 1035 ├── Design for 1.5x expansion 1036 ├── Use flexible containers 1037 └── max_length prevents overflow 1038 ``` 1039 1040 --- 1041 1042 # PART XVIII: ACCESSIBILITY 1043 1044 ## Standard 1045 1046 **Target:** WCAG 2.1 AA + Targeted Enhancements 1047 1048 ``` 1049 CORE REQUIREMENTS: 1050 ├── Color contrast: 4.5:1 (text), 3:1 (UI) 1051 ├── Full keyboard navigation 1052 ├── Screen reader compatibility (ARIA) 1053 ├── Visible focus indicators 1054 ├── Text resizable to 200% 1055 ├── No color-only information 1056 └── Error prevention for transactions 1057 1058 ENHANCED OPTIONS (User Toggle): 1059 ├── High contrast mode 1060 ├── Large text mode 1061 ├── Reduced motion mode 1062 └── Screen reader optimizations 1063 ``` 1064 1065 --- 1066 1067 # PART XIX: ERROR HANDLING 1068 1069 ## Model 1070 1071 **Approach:** Layered (User-Friendly + Technical Expandable) 1072 1073 ``` 1074 ERROR STRUCTURE: 1075 { 1076 "code": "ERR_INSUFFICIENT_BALANCE", 1077 "title": "Transaction couldn't be completed", 1078 "message": "You don't have enough ALPHA...", 1079 "explanation": "This transaction requires...", 1080 "action": "Add funds or reduce amount.", 1081 "technical": { "error_code": "0x4a2f", ... }, 1082 "help_link": "/help/errors/...", 1083 "retry_possible": true 1084 } 1085 1086 SEVERITY LEVELS: 1087 ├── Info (ℹ️) 1088 ├── Warning (⚠️) 1089 ├── Error (❌) 1090 └── Critical (🚨) 1091 ``` 1092 1093 --- 1094 1095 # PART XX: DESIGN SYSTEM 1096 1097 ## Foundation 1098 1099 **Approach:** Design Tokens + Reference Patterns 1100 1101 ``` 1102 FOUNDATION: 1103 ├── Tailwind CSS utility-first approach 1104 ├── Radix UI primitives (accessible) 1105 ├── Lucide icons 1106 └── Recharts / TradingView for charts 1107 ``` 1108 1109 ## Color Tokens 1110 1111 ``` 1112 BRAND: 1113 ├── alpha-primary #6366F1 (Indigo) 1114 ├── delta-primary #10B981 (Emerald) 1115 1116 SEMANTIC: 1117 ├── success #22C55E 1118 ├── warning #F59E0B 1119 ├── error #EF4444 1120 ├── info #3B82F6 1121 1122 TRADING: 1123 ├── long/buy #22C55E 1124 ├── short/sell #EF4444 1125 1126 PRIVACY: 1127 ├── private #6366F1 1128 ├── public #F59E0B 1129 ``` 1130 1131 ## Themes 1132 1133 ``` 1134 LIGHT: 1135 ├── background-primary #FFFFFF 1136 ├── foreground-primary #111827 1137 └── border-default #E5E7EB 1138 1139 DARK: 1140 ├── background-primary #0F0F0F 1141 ├── foreground-primary #F9FAFB 1142 └── border-default #374151 1143 1144 HIGH-CONTRAST: 1145 ├── background-primary #000000 1146 ├── foreground-primary #FFFFFF 1147 └── border-default #FFFFFF 1148 ``` 1149 1150 ## Typography 1151 1152 ``` 1153 FAMILIES: 1154 ├── sans Inter, system-ui 1155 ├── mono JetBrains Mono, Consolas 1156 └── display Inter (tight tracking) 1157 1158 SCALE: 1159 ├── xs 12px 1160 ├── sm 14px 1161 ├── base 16px 1162 ├── lg 18px 1163 ├── xl 20px 1164 ├── 2xl 24px 1165 ├── 3xl 30px 1166 ├── 4xl 36px 1167 └── 5xl 48px 1168 ``` 1169 1170 ## Spacing 1171 1172 ``` 1173 BASE UNIT: 4px 1174 1175 SCALE: 1176 ├── 1 4px 1177 ├── 2 8px 1178 ├── 3 12px 1179 ├── 4 16px 1180 ├── 6 24px 1181 ├── 8 32px 1182 └── 12 48px 1183 ``` 1184 1185 ## Animation 1186 1187 ``` 1188 DURATIONS: 1189 ├── fast 100ms 1190 ├── normal 200ms 1191 ├── slow 300ms 1192 └── slower 500ms 1193 1194 EASINGS: 1195 ├── default cubic-bezier(0.4, 0, 0.2, 1) 1196 ├── in cubic-bezier(0.4, 0, 1, 1) 1197 └── out cubic-bezier(0, 0, 0.2, 1) 1198 1199 REDUCED MOTION: 1200 └── Replace motion with opacity changes 1201 ``` 1202 1203 --- 1204 1205 # PART XXI: BRANDING & APP DISTRIBUTION 1206 1207 ## Brand Identity 1208 1209 ``` 1210 BRAND NAME: AC|DC Network 1211 1212 CHAIN NAMES: 1213 ├── Alpha Chain (ALPHA) - Monetary layer 1214 └── Delta Chain (DELTA) - Exchange layer 1215 1216 DOMAIN: ac-dc.network 1217 1218 WEB PROPERTIES: 1219 ├── ac-dc.network (main site) 1220 ├── docs.ac-dc.network (developer portal) 1221 ├── scanner.ac-dc.network (ALPHA-Scanner) 1222 └── app.ac-dc.network (web wallet) 1223 1224 TOKEN SYMBOLS: 1225 ├── ALPHA (AX) 1226 ├── DELTA (DX) 1227 └── sAX (synthetic alpha) 1228 1229 NAME SERVICE TLD: .blox 1230 ``` 1231 1232 ## App Distribution 1233 1234 ``` 1235 APPS: 1236 ├── AC|DC Wallet (consumer - iOS, Android, Desktop, Web) 1237 ├── AC|DC Governor (institutional - iOS, Android, Web) 1238 ├── AC|DC Messenger (companion - iOS, Android, Desktop) 1239 └── ac-dc (CLI - all platforms) 1240 1241 APP STORE CATEGORIES: 1242 ├── Wallet: Finance 1243 ├── Governor: Finance / Business 1244 └── Messenger: Utilities 1245 ``` 1246 1247 --- 1248 1249 # PART XXII: SUPPORT ARCHITECTURE 1250 1251 ## Model 1252 1253 **AI-First + Community Incentivized** 1254 1255 ``` 1256 TIER 1: AI Support (Immediate) 1257 ├── In-app AI assistant trained on ecosystem docs 1258 ├── Contextual help (knows current screen/action) 1259 ├── Available 24/7, all languages 1260 └── Cannot access keys, balances, or execute transactions 1261 1262 TIER 2: Community Forums (Radicle-based) 1263 ├── For issues AI can't resolve 1264 ├── Novel problems, edge cases 1265 ├── Incentivized contributions (DX revenue share) 1266 └── Becomes training data for AI 1267 1268 TIER 3: Organic Governance 1269 ├── No formal escalation to Governors 1270 ├── Systemic issues surface naturally 1271 └── Self-correcting through governance proposals 1272 ``` 1273 1274 ## Community Support Incentives 1275 1276 ``` 1277 MODEL: Daily DX Revenue Raffle for Top Contributors 1278 1279 CONTRIBUTION SCORING: 1280 ├── Answer marked "solved" +10 points 1281 ├── Answer upvoted +1 per vote 1282 ├── Documentation improvement +20 points 1283 ├── Bug report verified +15 points 1284 └── Translation accepted +5 points 1285 1286 DISTRIBUTION: 1287 ├── Daily pool from DX revenue (governance-set %) 1288 ├── Weighted by points earned 1289 ├── Raffle element for bonus allocation 1290 └── Anti-gaming via reputation history 1291 1292 TODO: Backend architecture for incentive system 1293 ``` 1294 1295 --- 1296 1297 # PART XXIII: ANALYTICS 1298 1299 ## Model 1300 1301 **Opt-In Anonymous** 1302 1303 ``` 1304 DEFAULT: Off (no data collected) 1305 1306 OPT-IN COLLECTS: 1307 ├── Feature usage frequency 1308 ├── Action completion rates 1309 ├── Error encounters (type only) 1310 ├── Performance metrics 1311 ├── Platform/OS/version 1312 └── Session duration 1313 1314 NEVER COLLECTED: 1315 ├── Addresses, balances, amounts 1316 ├── Transaction details 1317 ├── Names (name.blox) 1318 ├── IP addresses, device IDs 1319 ├── Location 1320 └── Any PII 1321 1322 DATA HANDLING: 1323 ├── Aggregated before storage 1324 ├── 90-day rolling retention 1325 └── Published aggregate stats 1326 ``` 1327 1328 --- 1329 1330 # PART XXIV: NETWORK ENVIRONMENTS 1331 1332 ## Testnet vs Mainnet 1333 1334 ``` 1335 MAINNET: 1336 ├── Standard theme (indigo/emerald) 1337 ├── No special indicators 1338 ├── Tokens: ALPHA, DX, sAX 1339 1340 TESTNET: 1341 ├── Orange theme 1342 ├── Persistent "TESTNET" indicator 1343 ├── Tokens: test-ALPHA, test-DX, test-sAX 1344 ├── Watermark on transaction screens 1345 1346 SWITCHING: 1347 ├── Confirmation required 1348 ├── Type "TESTNET" to confirm 1349 ├── Separate address books per network 1350 ``` 1351 1352 --- 1353 1354 # PART XXV: SOFTWARE RELEASE 1355 1356 ## Model 1357 1358 **Preview Channel + Governance Gate + Auto-Update** 1359 1360 ``` 1361 PREVIEW CHANNEL: 1362 ├── Opt-in only 1363 ├── Anonymous analytics: MANDATORY 1364 ├── Receives beta builds automatically 1365 ├── Contributes to release metrics 1366 1367 PRODUCTION CHANNEL: 1368 ├── Default for all users 1369 ├── Updates after governance approval 1370 ├── Automatic update, no user choice 1371 1372 RELEASE PIPELINE: 1373 1. Development → Preview (auto-push) 1374 2. Preview testing (min 7 days) 1375 3. Readiness metrics pass (crash <0.1%, critical bugs: 0) 1376 4. Governance proposal (DELTA 67%+) 1377 5. Approved → Production (auto-push to all) 1378 ``` 1379 1380 --- 1381 1382 # PART XXVI: DATA BACKUP & RECOVERY 1383 1384 ## Model 1385 1386 **IPFS Encrypted Backup, Seed-Derived Recovery** 1387 1388 ``` 1389 PHILOSOPHY: 1390 ├── Seed phrase is ONLY thing user must protect 1391 ├── Everything else encrypted on IPFS 1392 ├── Encryption key derived from seed 1393 ├── Recovery is automatic given seed 1394 1395 BACKUP CONTENTS: 1396 ├── Settings & preferences 1397 ├── Address book / contacts 1398 ├── Transaction labels & notes 1399 ├── Name service configuration 1400 ├── Device mesh config (re-pairing required) 1401 └── Off-ramp registrations 1402 1403 NOT BACKED UP (derived from chain/seed): 1404 ├── Balances 1405 ├── Transaction history 1406 ├── Private keys 1407 └── Positions 1408 1409 MECHANISM: 1410 1. Data change triggers backup 1411 2. Serialize and encrypt (AES-256-GCM) 1412 3. Upload to IPFS → get CID 1413 4. Store CID pointer on DELTA chain 1414 5. Recovery: seed → derive key → fetch CID → decrypt 1415 ``` 1416 1417 --- 1418 1419 # APPENDIX A: DECISION LOG 1420 1421 | # | Decision | Choice | 1422 |---|----------|--------| 1423 | 1 | Product Segmentation | Hub-and-Spoke | 1424 | 2 | Identity Architecture | Wallet-First with Paynym Root | 1425 | 3 | Stealth Address Implementation | Native Aleo Integration | 1426 | 4 | Name Service Architecture | Hybrid (registration to Paynym) | 1427 | 5 | DELTA Privacy Model | Full ZK Extension (dual address types) | 1428 | 6 | Derivation Path Structure | BIP47 Purpose-Based | 1429 | 7 | Payment Code Format | Aleo-Native | 1430 | 8 | Multi-Chain Identity | Multi-Curve Seed | 1431 | 9 | Name Service Namespace | Dual-Tier | 1432 | 10 | Name Service Pricing | Vickrey Auction + Fixed | 1433 | 11 | Wallet Recovery | Seed + Social + Shamir | 1434 | 12 | 2FA Mechanism | Device Mesh + FIDO2 + TOTP | 1435 | 13 | Device Mesh Sync | QR Pairing + Encrypted Backup | 1436 | 14 | Transaction Approval | User Choice (QR/Network/BLE) | 1437 | 15 | Spoke Distribution | Hub + Core / Operator / Public | 1438 | 16 | Spoke Integration | Hybrid (Core embedded, Operator separate) | 1439 | 17 | Unified Wallet Structure | Three Pockets (ALPHA/DX/sAX) | 1440 | 18 | ALPHA ↔ sAX Mechanism | True Synthetic (Collateralized) | 1441 | 19 | External Chain Scope | Full send/receive + imports | 1442 | 20 | Swap Architecture | P2P Adaptor Signatures | 1443 | 21 | Swap Orderbook Visibility | Transparent (encrypted mempool) | 1444 | 22 | Swap Griefing Protection | Reputation + Voluntary Bonds | 1445 | 23 | Private Swap Codes | Supported | 1446 | 24 | Swap Code Delivery | Name Service + Manual | 1447 | 25 | Trading Interface | Tiered (Simple/Pro) + MM Mode | 1448 | 26 | Trading Pairs | Basket + Governor + Governance-added | 1449 | 27 | ALPHA Valuation Governance | Genesis-set, Joint 67%/51% + 3mo delay | 1450 | 28 | Off-Ramp UX | Aggregated discovery, Governor settlement | 1451 | 29 | On-Ramp | P2P swap only | 1452 | 30 | Governance Portal | Embedded in wallet (conditional) | 1453 | 31 | DX Staking | Default staked, 1d unstake, 5d restake | 1454 | 32 | Governance Notifications | In-app + optional Messenger | 1455 | 33 | Governor Console | Minimal web/app, Easy Button aesthetic | 1456 | 34 | Validator Dashboard | Embedded in wallet, CLI/API primary | 1457 | 35 | ASG Operator Console | N/A - Trading Interface + MM Mode | 1458 | 36 | ALPHA-Scanner | Tiered (Dashboard/Explorer) | 1459 | 37 | Oracle Monitor | ALPHA-Scanner section + API | 1460 | 38 | Developer Portal | Phased + Radicle Integration | 1461 | 39 | Onboarding Flow | Quick Start + Progressive Nagging | 1462 | 40 | Localization | Multilingual from start, AI + Top 20 languages | 1463 | 41 | Accessibility | WCAG 2.1 AA + Enhancements | 1464 | 42 | Error Handling | Layered (User-Friendly + Technical) | 1465 | 43 | Design System | Tokens + Reference Patterns | 1466 | 44 | App Store Strategy | AC|DC Branding (Wallet, Governor, Messenger) | 1467 | 45 | Help/Support | AI-First + Community Incentives | 1468 | 46 | Analytics | Opt-In Anonymous | 1469 | 47 | Network Differentiation | Environment-Aware Theming | 1470 | 48 | Version Updates | Preview Channel + Governance + Auto-Update | 1471 | 49 | Data Backup | IPFS Encrypted, Seed-Derived Recovery | 1472 1473 --- 1474 1475 # APPENDIX B: DOCUMENT HISTORY 1476 1477 | Version | Date | Changes | 1478 |---------|------|---------| 1479 | 0.1 | 2027-01-14 | Initial draft through Decision #43 | 1480 | 1.0 | 2027-01-14 | Complete specification, 49 decisions | 1481 1482 --- 1483 1484 # APPENDIX C: IMPLEMENTATION DEPENDENCIES 1485 1486 ## External References 1487 1488 ``` 1489 FUNCTIONAL SPECIFICATION: 1490 └── ALPHA_DELTA_Functional_Specification_v2.1.md 1491 1492 UPSTREAM REPOSITORIES (Reference Only): 1493 ├── https://github.com/ProvableHQ/leo 1494 ├── https://github.com/ProvableHQ/snarkos 1495 ├── https://github.com/ProvableHQ/snarkvm 1496 └── https://github.com/ProvableHQ/sdk 1497 1498 CANONICAL REPOSITORIES: 1499 ├── https://github.com/BlockBlox-MD/snarkOS 1500 └── https://github.com/BlockBlox-MD/snarkVM 1501 ``` 1502 1503 ## Technology Stack 1504 1505 ``` 1506 CORE: 1507 ├── Rust (wallet-core library) 1508 ├── snarkVM bindings (ZK proofs) 1509 └── Multi-curve cryptography (BLS12-377, secp256k1, ed25519) 1510 1511 PLATFORM SHELLS: 1512 ├── iOS: Swift + Rust FFI 1513 ├── Android: Kotlin + Rust FFI 1514 ├── Desktop: Tauri (Rust) 1515 ├── Web: Rust → WASM 1516 └── CLI: Rust native 1517 1518 UI FRAMEWORK: 1519 ├── Tailwind CSS 1520 ├── Radix UI primitives 1521 ├── Lucide icons 1522 └── Recharts / TradingView 1523 1524 INFRASTRUCTURE: 1525 ├── IPFS (encrypted backups) 1526 ├── Radicle (documentation, forums) 1527 └── Chainlink (oracles) 1528 ``` 1529 1530 --- 1531 1532 **END OF SPECIFICATION** 1533 1534 **Document Version:** 1.0 1535 **Date:** January 14, 2027 1536 **Status:** Complete — Ready for Implementation 1537 1538 **For Implementation By:** 1539 - wallet-core team (Rust library) 1540 - Platform shell teams (iOS, Android, Desktop, Web) 1541 - CLI team 1542 - ALPHA-Scanner team 1543 - Developer Portal team 1544 - Documentation team 1545