Protocol Fees
NullGraph uses a configurable fee mechanism to sustain protocol development, incentivize participation, and build a treasury for future ecosystem growth.The default fee is 2.5% (250 basis points) deducted from every bounty settlement. Fees are routed to a protocol-controlled treasury wallet.
Fee Model Overview
When Fees Apply
Fees are only charged on successful bounty settlements via theapprove_bounty_submission instruction.
NKA Submission
No fee — researchers submit null results for free
Bounty Creation
No fee — creating bounties is free (only escrow cost)
Bounty Approval
2.5% fee — deducted from reward on settlement
Fee Calculation
Fees are calculated using basis points (1 bp = 0.01%):All arithmetic uses checked operations (
checked_mul, checked_div, checked_sub) to prevent overflow and underflow attacks.Protocol State Configuration
Fees are stored in the globalProtocolState singleton:
["protocol_state"]
Initialization
The protocol is initialized once viainitialize_protocol:
Treasury Distribution
Fee Collection Flow
When a bounty is approved, the vault transfers fees to the treasury in the same transaction:Atomic Settlement
Both transfers happen in one transaction — researcher payout and treasury fee are inseparable. Either both succeed or both fail.
Treasury Account Derivation
The treasury receives BIO via its Associated Token Account (ATA):Fee Breakdown Example
Let’s trace a 1000 BIO bounty settlement:
On-chain event:
Fee Basis Points Explained
Basis points provide precision for fractional percentages (like 2.5%) using only integer arithmetic — critical for on-chain programs.
Why 2.5%?
NullGraph’s fee model balances sustainability with accessibility:Lower than DeFi
Most DeFi protocols charge 3-5% fees. NullGraph’s 2.5% is competitive for a scientific data marketplace.
No Creator Fee
Unlike NFT marketplaces, bounty creators pay zero fees — only settlement is taxed, incentivizing bounty creation.
Researcher-Friendly
97.5% payout ensures researchers capture most of the value they create.
Sustainable Treasury
Fees accumulate in BIO, building a war chest for grants, development, and ecosystem growth.
Treasury Use Cases
Fees collected in the treasury can fund:- Protocol Development — smart contract upgrades, frontend improvements
- Community Grants — funding for researchers and BioDAOs
- Verification Incentives — rewards for NKA peer review and validation
- Marketing & Growth — ecosystem expansion, conference sponsorships
- Liquidity Mining — future token incentives for participation
Treasury governance mechanisms are not yet implemented. The current treasury wallet is controlled by the protocol authority. Future versions may introduce DAO governance.
Fee Events & Tracking
Every settlement emits aBountyFulfilled event with exact fee amounts:
Security: Safe Math
All fee calculations use checked arithmetic to prevent exploits:Overflow Protection
Prevents attackers from causing integer overflow with massive reward amounts
Underflow Protection
Ensures
payout = total - fee never underflows (e.g., if fee > total)Deterministic Failure
Returns clear
FeeOverflow error instead of silent corruptionAuditable
Explicit error handling makes fee logic easy to audit
Frontend Fee Display
Show fee breakdown before settlement:Querying Treasury Balance
Check total fees collected:No Fees on Closed Bounties
When a bounty is closed (not approved), the full vault balance returns to the creator:Fee Rate Immutability
The current implementation sets the fee rate once at initialization:- ✅ Transparent — fee rate is public, stored on-chain
- ✅ Predictable — users know exact fees before transacting
- ❌ Not governable — cannot be changed without program upgrade
Comparison with Other Protocols
NullGraph’s 2.5% is competitive with Web3 marketplace standards and lower than most DeFi lending protocols.
Next Steps
BIO Integration
Learn how BIO tokens power the bounty economy
Bounty Marketplace
Explore the full bounty lifecycle and escrow mechanics