DigiDollar Implementation Specification v5.0 - Taproot Enhanced #324
Replies: 12 comments 10 replies
-
Sogobi means "Earth," and Napiasi means "Money" in Shoshoni, a Native American language. May the DigiDollar stablecoin running on DigiByte become decentralized Earth Money. |
Beta Was this translation helpful? Give feedback.
-
Great spec document @SogobiNapiasi! Curious about the collateral rates. Typically in "bear markets", asset value for DGB declines by 95-98%. How is that being taken into account with the longer timeframe collateralization rates? Will it protect folks in that type of situation? |
Beta Was this translation helpful? Give feedback.
-
Wow! This is an incredible blueprint for building the DigiDollar on top of DigiByte. After reading this, I believe we 100% have the ability to pull this off. There are still a lot of questions, though, and I would encourage people to ask as many questions as they can, and let's start hammering out the details. I will be compiling a list of my own questions here today. We will need to finish $DGBv8.23 first. We can probably start getting ready for a DigiDollar soft fork in 8.23 as well. But DigiByte v9.23.0 would be the DigiDollar version, as it will need a soft fork and lots of consensus changes, and loads of testing. I think this is feasible to pull off by the end of 2026 into 2027. Possibly sooner. Can't wait to start diving in more. First questions that come to mind is what happens if DigiDollar ever gets under collateralized? How can we make every person running a core wallet full node a price oracle? How can we add advanced smart contracts to MAST redemption scripts? What will the new Core Wallet GUI layout look like exactly? We should do a visual refresh with 8.23. |
Beta Was this translation helpful? Give feedback.
-
Love it!
Last because these 3 things are massively important. I wonder if we could at least set up a mining capability with a cap to at least allow some to be in circulation without the hope of timing and discovery. Just some thoughts. |
Beta Was this translation helpful? Give feedback.
-
This is truly remarkable and exciting. Couple questions come to my mind:
|
Beta Was this translation helpful? Give feedback.
-
The Recursive Minting Attack ProblemI've identified a critical vulnerability in the proposed DigiDollar collateral system that needs immediate attention. After discussions with several community members, it's become clear that the 100% collateralization ratio for 10-year locks creates a significant exploit opportunity. The Attack VectorHere's how someone could game the system:
While Digibyte's 21 billion coin cap and the price appreciation from locked supply would eventually limit this attack, it could be exploited significantly before those natural limits kick in. Multiple bad actors could execute this simultaneously, creating artificial DigiDollar inflation without proportional backing. My Proposed SolutionI'm proposing a sliding collateralization scale based on lock duration:
This structure effectively limits the recursive minting attack. At 400% collateral, you can only recover 25% of your locked value in DigiDollars. Let me trace through the math:
The attack becomes impractical after just a few iterations, with total minting capped at $333.33 DD from the original $1,000. Additional Mitigation IdeasI've been thinking about other ways we could strengthen the system, and I'd love to get community feedback on these ideas: Wallet-Level Minting Cooldowns: Since tracking cooldowns by address could be circumvented by simply sending coins to a new address, what if we implemented the cooldown at the wallet level? The core wallet GUI could enforce a 24-hour cooldown after the first mint. If someone tries to mint again within 24 hours, it extends to 48 hours. This wouldn't stop someone from using multiple wallets, but it adds friction to the process. Supply Caps or Dynamic Adjustments: We might want to consider some kind of initial maximum cap on total DigiDollar supply, or maybe implement dynamic adjustments based on how much DGB is locked up. I'm not entirely sure how the mechanics would work yet - perhaps as more of the total DGB supply gets locked, we could require higher collateral ratios across the board? This needs more thought. Minting Fees: Small fees that go into a stability fund could make repeated minting costly enough to discourage gaming the system. Emergency Mechanisms: If we detect unusual minting patterns or volumes, we could have circuit breakers that temporarily adjust requirements. Moving ForwardThis multi-layered approach should create enough friction to make the recursive minting attack impractical while still keeping DigiDollar accessible for legitimate users. The higher collateral requirements on shorter timeframes also encourage genuine long-term thinking, which aligns with our vision for DigiDollar as a stable store of value. I think the sliding collateralization scale is the core solution, but I'm open to discussing these additional ideas with the community. What other creative solutions might we consider? How do we balance security with usability? The important thing is that we address this vulnerability before launch. We need to protect the integrity of DigiDollar from day one while still making it an attractive option for our users. |
Beta Was this translation helpful? Give feedback.
-
I would say once past 3 years why not add a couple more stops on the scale? 3 years to 10 years is quite a gap. Maybe add a 5/7 year stops. |
Beta Was this translation helpful? Give feedback.
-
Nice work @SogobiNapiasi. Some ideas..
|
Beta Was this translation helpful? Give feedback.
-
I shared a post on the X social media platform 7/11/25 and tagged StabilityNexus and Dr. Bruno Woltzenlogel Paleo to ask their opinions. The comment received a response 7/23/25, “submit the paper to the first stability workshop, the deadline got extended”. In my opinion, by submitting the “324 DigiDollar Implementation Specification v5.0” to the stability workshop, some of the issues identified can be ironed out, issues not yet identified can be flushed out, you’ll be amongst industry leaders and innovators who are focusing on this specific area and that can be the difference in the DigiDollar being successful in the DigiByte ecosystem. I can think of “50 Revolutionary DigiDollar Use Cases: $500+ Trillion Market Opportunity”, why to submit the specifications to stability workshop. Please consider. Sincerely, |
Beta Was this translation helpful? Give feedback.
-
Yes. It would be great to have a paper about DigiByte's stablecoin submitted to the workshop! |
Beta Was this translation helpful? Give feedback.
-
are we leveraging AI to help address some of the issues raised above? For what it’s worth, I spent a good amount of time running the v5.0 spec through LLMs, including digging into a number of the concerns flagged in the comments, and surfaced quite a few solid solutions in the form of a v5.0 enhancement proposal. |
Beta Was this translation helpful? Give feedback.
-
On that note: Proposed Enhancements for DigiDollar v5.0 – Additions, Fixes, Community-Aligned Improvements, and Code Snippets (Assisted by LLMs) First off, massive kudos on the v5.0 spec @SogobiNapiasi, integrating Taproot for privacy, Schnorr oracles, and dynamic collateral ratios is a brilliant evolution from the whitepaper. I see huge potential here for tax-efficient, decentralized stablecoins. With the assistance of LLMs to help brainstorm and structure these ideas (I'm happy to be transparent about using AI tools to enhance my contributions), I've built on the great feedback in this thread (e.g., undercollateralization risks from @JaredTate, bear market volatility from @ycagel, liquidity concerns from @nadav32p, and new points like market-top leveraging from @ThatStanGuy) to propose some targeted additions and fixes for a v6.0 draft. These include simulated C++-style code snippets (pseudocode adaptable to DigiByte Core files like I've also incorporated responses to recent comments: @nadav32p's enthusiastic support for the ecosystem vision reinforces the tax-optimization use case, while @ThatStanGuy's concern about over-leveraging at market tops (e.g., locking up supply for DigiDollars during frenzies) is addressed in the volatility and liquidation fixes below, adding caps on total locked supply and frenzy detection could prevent systemic risks. These could roll out in phases post-Taproot (aligning with @JaredTate's v9.23.0 timeline), starting with audits and testnet sims. What does everyone think, viable for v6.0? Suggested Additions to the SpecThese are optional features that leverage Taproot's strengths for future-proofing, with code examples:
Fixes for Key ConcernsAddressing thread-highlighted issues with practical solutions and code:
Lets build this. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
DigiDollar Implementation Specification v5.0 - Taproot Enhanced
This document is intended to be a living document modified and improved by community discussion.
Executive Summary
This document provides a technical specification for implementing DigiDollar as a native stablecoin on the DigiByte blockchain, leveraging the recently activated Taproot upgrade.
In Simple Terms: DigiDollar is a digital currency that always equals $1 USD, built directly into DigiByte. When you want to create DigiDollars, you lock up DigiByte coins as collateral (like putting down a deposit). The system uses DigiByte's newest technology called Taproot to make all transactions look the same (better privacy), cost less in fees, and work more efficiently.
The implementation extends DigiByte Core v8.22.0 with new opcodes and consensus rules to enable a fully decentralized USD-pegged stablecoin backed by time-locked DGB collateral. By utilizing Taproot's P2TR outputs, Schnorr signatures, and Tapscript, DigiDollar achieves enhanced privacy, efficiency, and flexibility while maintaining the security and simplicity of a UTXO-based design.
Table of Contents
1. Architecture Overview
1.1 System Components
What This Section Covers: Think of DigiDollar as a new feature being added to DigiByte, like adding a new app to your phone. This section explains all the different parts that work together to make DigiDollar function.
The DigiDollar implementation leverages Taproot to provide enhanced functionality:
Consensus Layer Modifications
In Simple Terms: These are the core rules that all DigiByte nodes must follow. Like traffic laws that everyone must obey, these rules ensure everyone agrees on what's valid.
Taproot Script System
In Simple Terms: Taproot is like having a Swiss Army knife instead of carrying multiple tools. It lets us do many things efficiently while keeping transactions private.
Oracle Infrastructure
In Simple Terms: Oracles are like trusted news reporters who tell the blockchain the current price of DigiByte in US dollars. We use 15 oracles and need at least 8 to agree on the price.
Price Stability Mechanism
In Simple Terms: This is like a safety system that monitors if the DigiByte price is changing too quickly. If prices are too volatile, it temporarily pauses new DigiDollar creation to protect users.
Wallet Enhancements
In Simple Terms: Your wallet software gets new features to handle DigiDollars, like being able to see your balance, send them to others, and convert between DGB and DigiDollars.
1.2 Design Principles
These Are Our Core Values: Like building a house with a strong foundation, these principles guide every decision in building DigiDollar.
2. Core Consensus Changes
What This Section Covers: This section explains the fundamental changes to DigiByte's rules that make DigiDollar possible. Think of it as updating the "laws" of the blockchain to recognize and handle this new type of money.
2.1 Tapscript Integration
In Simple Terms: We're adding new "commands" (opcodes) to DigiByte's scripting language. These are like new vocabulary words that let the blockchain understand DigiDollar operations.
2.1.1 OP_DIGIDOLLAR in Tapscript Context
What This Does: This code defines the new commands. OP_DIGIDOLLAR is our main command that marks outputs as containing DigiDollars (not regular DGB).
2.1.2 Tapscript Validation Rules
What This Does: This ensures DigiDollar operations only work with DigiByte's newest transaction format (Taproot). It's like requiring a specific type of container for shipping certain goods.
2.2 P2TR-Based Transaction Validation
In Simple Terms: This section defines how the network checks if DigiDollar transactions are valid. It's like having quality control inspectors who verify every transaction follows the rules.
2.2.1 Enhanced DigiDollar Validation
What This Function Does:
2.3 Updated Consensus Parameters
In Simple Terms: These are the "settings" for DigiDollar. Like setting the rules for a game, these parameters define things like minimum amounts, time periods, and safety thresholds.
Key Settings Explained:
2.4 Treasury-Based Collateral Model
In Simple Terms: Just like U.S. Treasury bonds pay different interest rates based on how long you lock up your money, DigiDollar requires different amounts of collateral based on your chosen lock-up period. Shorter periods need more collateral (higher safety margin), while longer periods can use less.
Why This Makes Sense:
2.4.1 Collateral Ratio Table
2.4.2 Implementation Details
3. Taproot-Enhanced Script System
What This Section Covers: This explains how we use Taproot's advanced features to create flexible and private DigiDollar transactions. Think of it as designing different "locks" for your digital money that can be opened in different ways.
3.1 P2TR DigiDollar Output Structure
In Simple Terms: P2TR (Pay-to-Taproot) is the newest and most advanced way to "lock" DigiBytes and DigiDollars. It's like having a smart lock that can be opened with either a simple key OR a complex combination, but nobody can tell which method you'll use until you actually use it.
3.1.1 Taproot Output Construction
What This Function Does:
3.1.2 MAST-Based Redemption Paths
What This Creates: Three different ways to unlock your collateral:
MAST Explained: MAST (Merkelized Alternative Script Trees) is like having multiple doors to exit a building, but only the door you use is revealed. The other doors remain secret.
3.2 Schnorr-Based Script Operations
In Simple Terms: Schnorr signatures are a newer, better way to sign transactions. They're smaller, faster to verify, and enable cool features like combining multiple signatures into one.
3.2.1 DigiDollar Transfer Script
What This Does: Creates the simplest possible way to transfer DigiDollars between users. It optimizes for the "key path" - meaning it looks just like a regular DigiByte transaction, hiding the fact that it contains DigiDollars.
4. Oracle System with Schnorr Threshold Signatures
What This Section Covers: This explains how DigiDollar knows the current price of DigiByte in US dollars. It's like having multiple trusted price reporters, and we need most of them to agree before accepting a price.
4.1 Enhanced Oracle Configuration
In Simple Terms: We have 15 independent "price reporters" (oracles) who constantly tell the blockchain what DGB is worth in USD. To prevent manipulation, we require at least 8 of them to agree on the price. This is like requiring multiple witnesses to verify something important.
4.2 Schnorr Oracle Price Structure
What This Stores: Each price report from an oracle contains:
Why This Matters: This structure ensures price data is authentic, fresh, and can't be reused maliciously.
4.3 Threshold Signature Validation
What This Does: This is the "voting mechanism" for oracle prices:
The Magic of OP_CHECKSIGADD: This new opcode lets us efficiently verify multiple signatures in one operation, making the system faster and cheaper than old methods.
5. Transaction Types with P2TR
What This Section Covers: This explains the three main types of DigiDollar transactions: Minting (creating new DD), Transferring (sending DD to others), and Redeeming (converting DD back to DGB). Each uses Taproot for privacy and efficiency.
5.1 Mint Transaction with Taproot
In Simple Terms: Minting is like going to a bank and depositing gold (DGB) to get paper money (DigiDollars). You lock up your DGB as collateral, and the system creates new DigiDollars for you to use.
5.1.1 Structure
What This Shows: The anatomy of a mint transaction:
5.1.2 Mint Transaction Creation
What This Function Does:
Example: If you want $100 in DigiDollars and DGB is $0.01:
5.2 Transfer Transaction with Key Path Spending
In Simple Terms: Transferring DigiDollars is like sending an email - quick and simple. Thanks to Taproot's "key path," these transactions look exactly like regular DigiByte transactions, keeping your DigiDollar usage private.
5.2.1 Efficient P2TR Transfers
What This Function Does:
Privacy Benefit: Nobody can tell this is a DigiDollar transaction - it looks identical to a regular DGB transfer!
5.3 Redemption Transaction with Script Path
In Simple Terms: Redemption is like returning to the bank to get your gold (DGB) back by giving them your paper money (DigiDollars). You must "burn" (destroy) the DigiDollars to unlock your collateral.
5.3.1 MAST-Based Redemption
What This Function Does:
Important: You can only redeem after your timelock expires (30 days to 10 years, depending on what you chose), unless there's an emergency situation validated by oracles.
6. Price Volatility Protection
What This Section Covers: This explains how DigiDollar protects users from wild price swings. Think of it as an automatic safety brake that activates when the DGB price is moving too fast.
6.1 Tapscript-Enhanced Volatility Detection
In Simple Terms: This system constantly monitors the DGB price. If the price changes more than 20% in an hour, it temporarily stops new DigiDollar creation. This protects both new users and the system from extreme market conditions.
How It Works:
Why This Matters: Prevents people from gaming the system during price crashes or spikes.
6.2 Dynamic Collateral with MAST
In Simple Terms: During volatile markets, the system can require more collateral. It's like a bank asking for a bigger down payment when conditions are risky. MAST lets us encode different collateral levels that activate based on market conditions.
Three Collateral Levels:
7. Wallet Integration
What This Section Covers: This explains how your DigiByte wallet software is upgraded to handle DigiDollars. Think of it as adding a new "currency compartment" to your digital wallet.
7.1 Taproot-Aware Wallet Functions
In Simple Terms: Your wallet needs new abilities to:
Key Features:
7.2 Enhanced GUI Components
In Simple Terms: The wallet's user interface gets new screens and features specifically for DigiDollar:
Visual Elements:
8. RPC Interface Extensions
What This Section Covers: RPC (Remote Procedure Call) commands are how advanced users and developers interact with DigiDollar through the command line. Think of these as "power user" commands for those who want direct control.
8.1 Taproot-Enhanced RPC Commands
In Simple Terms: These are new commands you can type to:
Why RPC Matters: Developers can build applications, exchanges can integrate DigiDollar, and power users can automate their operations.
8.2 Example Usage
Real Examples You Can Run: These show how to use the commands in practice. Each command returns useful information about your transaction or position.
9. Running a DigiDollar Oracle Node
What This Section Covers: This section explains how to run your DigiByte Core wallet as an Oracle price node, providing critical price data to the DigiDollar system. Think of it as volunteering to be one of the trusted price reporters for the network.
9.1 Oracle Node Overview
In Simple Terms: Oracle nodes are special DigiByte Core wallets that fetch DGB/USD prices from exchanges and broadcast them to the network. Just like DNS seed nodes help peers find each other, oracle nodes help the network know the current DGB price.
How It Works:
9.2 Hardcoded Oracle Implementation
Similar to Seed Nodes: Just like DigiByte has hardcoded DNS seeds (seed.digibyte.io, etc.), oracle nodes will be hardcoded into the client:
9.3 Running an Oracle Node
9.3.1 Prerequisites
What You Need:
9.3.2 Configuration
9.3.3 Oracle Node Commands
9.4 Oracle Selection Mechanism
Network-Based Selection: While 30 oracles are hardcoded, the network dynamically selects which to use:
9.5 Incentive Mechanisms
How to Encourage Oracle Participation:
9.5.1 Direct Incentives
Oracle Rewards Pool:
Reliability-Based Rewards:
9.5.2 Indirect Incentives
Reputation System:
Staking Requirements (Future):
Business Incentives:
9.6 Scaling to Hundreds of Oracles
Future Expansion Plan:
9.7 Technical Implementation Details
9.7.1 Price Broadcasting Protocol
9.7.2 Exchange Price Fetching
9.7 Option B: DNS Seeder Price Feeds
Alternative Approach: Instead of dedicated oracle nodes, leverage existing DNS seed infrastructure.
9.7.1 How DNS Seeder Price Feeds Would Work
The Concept: DNS seeders already provide peer discovery. They could also provide price data:
9.7.2 Implementation for DNS Operators
Simple Script for Seeders:
9.7.3 Node Implementation
9.7.4 Advantages of DNS Approach
9.7.5 Disadvantages of DNS Approach
9.8 Recommendation: Hybrid Approach
Best of Both Worlds: Start with Option B (DNS) for simplicity, upgrade to Option A (dedicated oracles) for security:
Phase 1 (Launch): Use DNS seeder prices
Phase 2 (6 months): Add dedicated oracle nodes
Phase 3 (1 year): Phase out DNS prices
10. DigiDollar Fungibility and Redemption
What This Section Covers: This explains how DigiDollar redemption works and confirms that all DigiDollars are fully fungible - you don't need the exact ones you minted.
10.1 Full Fungibility Confirmed
In Simple Terms: DigiDollars work like regular money - a dollar is a dollar, no matter where it came from. You can:
10.2 How Redemption Works
10.3 Why This Matters
Benefits of Fungibility:
What This Enables:
10.4 Technical Implementation
This design ensures DigiDollars function as a true fungible currency while maintaining the security of collateral-backed minting.
11. Security Considerations
10.1 Taproot-Specific Security Enhancements
10.1.1 Enhanced Privacy
10.1.2 Schnorr Signature Security
10.1.3 Script Path Protection
10.2 Attack Mitigation
10.2.1 Oracle Manipulation (Enhanced)
10.2.2 MAST Path Exploitation
12. Implementation Phases
Phase 1: Taproot Foundation
Phase 2: Oracle Integration
In Simple Terms: Implement the price oracle system (start with DNS approach).
Phase 2a: DNS-based price feeds
Phase 2b: Dedicated oracle nodes (if needed)
Phase 3: MAST Implementation
Phase 4: Advanced Features
Phase 5: Wallet Enhancement
Phase 6: Production Deployment
13. Testing Strategy
13.1 Taproot-Specific Tests
13.2 Integration Tests with Taproot
14. Implementation Blueprint
14.1 New Files to Create
Taproot-Specific Modules
14.2 Modified Files
Script System Updates
14.3 New Classes
Taproot Classes
14.4 Build System Updates
Conclusion
In Simple Terms: DigiDollar represents a major advancement for DigiByte - a native stablecoin that's always worth $1 USD, built using the latest blockchain technology. By leveraging Taproot, we've created a system that's private, efficient, and secure.
This Taproot-enhanced specification transforms DigiDollar into a privacy-preserving, efficient, and flexible stablecoin system. By leveraging P2TR outputs, Schnorr signatures, and MAST, we achieve:
What This Means for Users:
The implementation maintains full UTXO compatibility while providing cutting-edge features that position DigiDollar as the most advanced stablecoin on any UTXO blockchain.
Next Steps: With this specification, developers can begin implementing DigiDollar on the DigiByte blockchain, bringing stable, decentralized digital dollars to the DigiByte ecosystem.
Beta Was this translation helpful? Give feedback.
All reactions