VerifyTrade
VerifyTrade is a fair DeFi trading infrastructure that eliminates MEV (Maximal Extractable Value) attacks and provides cryptographic proof of fair execution for every trade. MEV bots cost DeFi traders
Videos
Description
VerifyTrade is a fair DeFi trading infrastructure that eliminates MEV (Maximal Extractable Value) attacks and provides cryptographic proof of fair execution for every trade. MEV bots cost DeFi traders over $1.2 billion per year through front-running, sandwich attacks, and oracle manipulation — and until now, there was no way to prove a trade was executed fairly.
VerifyTrade solves this through a four-layer trust stack powered entirely by the 0G network:
AES-256-GCM Encryption → 0G Storage — Orders are encrypted client-side and stored on 0G Galileo Testnet before execution. MEV bots see nothing in the mempool.
0G Compute TEE — An AI model inside a Trusted Execution Environment verifies trade fairness and produces a signed attestation. Inference is verifiable via the 0G Compute marketplace.
0G KV Store — Per-trader trade indexes are written to 0G's key-value layer, enabling instant trade history without blockchain scanning.
0G Agentic ID (ERC-7857) — The executor is registered as Token #101 on the 0G Agentic ID contract, giving it a verifiable on-chain identity that signs every attestation.
On-chain fairness proofs are recorded to both Arbitrum Sepolia and 0G Galileo via smart contracts (VerifiableTradeExecutor, FairnessProof, MevRegistry). Traders get a public verification URL (/verify?id=X) and a downloadable compliance PDF with the full cryptographic audit trail. The dashboard shows live 0G network status, real-time token prices from 0G Compute AI inference, and the on-chain agent card — all auto-refreshed.
Progress During Hackathon
<ul><li><p><strong>Smart contracts</strong>: 3 production contracts (VerifiableTradeExecutor, FairnessProof, MevRegistry) + VerifyTrade order router — deployed to both Arbitrum Sepolia and 0G Galileo Testnet. 72/72 tests passing.</p></li><li><p><strong>0G Storage (real SDK)</strong>: Integrated <code data-inline="true" spellcheck="false">@0gfoundation/0g-storage-ts-sdk</code> — encrypted orders are live-uploaded to Galileo testnet using Indexer + MemData, returning a content-addressed root hash.</p></li><li><p><strong>0G Compute</strong>: Integrated <code data-inline="true" spellcheck="false">@0gfoundation/0g-compute-ts-sdk</code> — AI fairness verdicts and live token price oracle via OpenAI-compatible inference on 0G Compute providers.</p></li><li><p><strong>0G KV Store</strong>: Trade indexes written per-trader using <code data-inline="true" spellcheck="false">KvClient</code> + <code data-inline="true" spellcheck="false">Batcher</code> on the 0G storage layer.</p></li><li><p><strong>0G Agentic ID</strong>: Minted ERC-7857 Token #101 on Galileo (<code data-inline="true" spellcheck="false">0x2700F6A3e505402C9daB154C5c6ab9cAEC98EF1F</code>). Agent auto-authorizes traders on first submission, signs every attestation.</p></li><li><p><strong>Dual-chain deployment</strong>: All contracts deployed to Arbitrum Sepolia (primary) + 0G Galileo Testnet (native), with chain-selector in the API layer.</p></li><li><p><strong>Counterfactual fairness analysis</strong>: Each executed trade returns a "without VerifyTrade" slippage comparison so users can see exactly how much MEV protection saved them.</p></li><li><p><strong>Live dashboard</strong>: 0G Network status panel (Storage/Compute/KV/AgenticID), real-time token prices (via 0G Compute AI), agent detail page with ERC-7857 capabilities.</p></li><li><p><strong>Public attestation portal</strong>: <code data-inline="true" spellcheck="false">/verify?id=X</code> generates a shareable URL that shows the full trust chain — 0G Storage CID → TEE measurement → on-chain proof TX → agent tag.</p></li><li><p><strong>Compliance PDF</strong>: jsPDF-generated audit report including attestation hash, counterfactual analysis, on-chain TX, and TEE measurement — downloadable from any trade result.</p></li><li><p><strong>Full Next.js 14 frontend</strong>: Trade form, execute flow, MEV stats charts, fairness comparison panel, agent page — zero TypeScript errors, production build clean.</p></li></ul>
Tech Stack
Fundraising Status
<p>Not currently fundraising. This project was built independently for the 0G APAC Hackathon 2026. Open to ecosystem grants and partnerships.</p>