Solo · Midnight Hackathon (Confidential DeFi track) · July 2026
EdgeProof
A solo build on Midnight, a blockchain for private smart contracts, that solves the trader's paradox: you cannot prove your track record without handing over the trade history that is your edge. EdgeProof commits a private trade log on-chain, then generates zero-knowledge proofs of threshold claims about it — net P&L positive, win rate at or above a threshold, max drawdown at or below a limit — that anyone can verify on the public ledger. The trades stay in local private state the whole time; what lands publicly is a salted commitment and the proven claims.
0
Trades revealed
9/9
Contract tests
3
ZK claims proven on-chain
~24 s
Per-proof time
Demo



What it does
- Proves three claims about a trading record — net P&L is positive, win rate is at or above a threshold, max drawdown is at or below a limit — as real zero-knowledge proofs, each submitted as its own on-chain transaction, while the individual trades never leave the trader's machine.
- Binds every claim to one committed log: each circuit first checks that a salted SHA-256 commitment on the public ledger matches the private trades being proven, so a trader cannot cherry-pick a different history for each claim.
- Refuses to lie. Point the same contract at a losing record and ask it to prove profit, and the assertion fires during proof generation — the proof simply cannot be produced. Nine contract-level tests cover each claim proving on a passing log, being rejected on a failing one, and staying commitment-bound.
- Works around real constraints in Compact, Midnight's contract language: no signed integers (P&L is stored unsigned with a bias), no division (win rate becomes wins x 100 >= threshold x total, and drawdown becomes peak <= equity + limit), and no mutable loop accumulators (running totals are witnessed as a prefix array and verified in-circuit, one assertion per index). That last choice keeps proofs cheap — a 32-trade claim proves in about the same time as a trivial counter.
- Takes real trades, not just demo data: a TradingView 'List of Trades' CSV adapter maps an actual export into the canonical schema, verified end-to-end from CSV to a deployed contract with all claims proven.
- Ships a React performance card that reads the verified claims live from the chain, decoding the ledger in the browser via Midnight's WASM with no server involved, plus a local file preview that parses a trade file entirely in-browser and never uploads it.
- Honest status: everything above is proven end-to-end on a local Midnight stack — real deploys, real proofs, real ledger reads. A public testnet deploy was attempted and remains blocked on the initial wallet sync being compute-bound, not on the contract or the proofs.