Search projects, hackathons, sponsors and tech

    ← All projects

    ZubiDubi

    Self-custodial early exit liquidity for maturing DeFi assets, priced by time, risk, and exposure.

    Demo

    About

    ZubiDubi is self-custodial early exit liquidity for locked, delayed redemption DeFi assets like Pendle PT tokens, LRT receipts, and vault withdrawal shares. These assets are worth full value at maturity but illiquid before it, and today holders either wait or sell off-chain at an opaque discount. Generic AMMs cannot price this correctly because they have no concept of time to maturity. Built by modifying SwapVM itself, not wrapping it: a reusable instruction library adds oracle validation, exposure limits, and term-discount pricing as native opcodes. Many DeFi assets are transferable but not instantly redeemable: Pendle-like Principal Tokens, LST/LRT withdrawal receipts, vault withdrawal claims, bridge receipts, and other maturing positions. Holders who need liquidity early often must wait, sell into thin markets, or accept opaque OTC/RFQ pricing. ZubiDubi creates a programmable early-exit market for those assets. Makers publish liquidity strategies from their own wallets instead of locking funds into isolated pools. Sellers bring a maturing claim, and ZubiDubi routes the sale across makers who can actually deliver liquid USDC/WETH at that moment. The maker pays liquid tokens now and receives the maturing claim now, taking on duration and redemption risk in exchange for a discount. The core idea is a programmable term-liquidity book: makers define risk curves based on oracle-backed value, time to maturity, inventory, liquidity depth, risk tier, and exposure limits. The route executor checks real deliverable liquidity onchain, skips insolvent makers, splits fills across the best executable strategies, and reverts if the requested trade cannot fully settle. ZubiDubi also introduces shared term-risk budgets. A maker can assign sibling Aqua strategies to one global receipt/quote budget, so when one strategy fills, the rest lose capacity and start quoting worse prices as utilization rises. This turns wallet-held liquidity into a coordinated term-liquidity book rather than isolated strategies racing the same balance. The deployed demo includes verified Sepolia contracts, real Sepolia WETH/USDC/LINK-backed PT-style receipt assets, Chainlink oracle pricing, a deployed Graph subgraph, a hosted solver API, and a frontend for markets, selling, making strategies, portfolio issuance/redemption, and playground proofs.

    How it's made

    ZubiDubi is built on the official 1inch Aqua and SwapVM codebases, with SwapVM extended for term-liquidity markets. On the contract side, we modified the Aqua SwapVM router and added a reusable instruction library instead of one app-specific mega-opcode. The library has three modular instructions: BACKING_ORACLE_CHECK: validates the receipt/quote pair, reads oracle-backed par value, enforces stale-oracle protection, maturity bounds, and optional secondary-oracle deviation haircuts. EXPOSURE_CAP: enforces maker max receipt exposure, max quote-token notional, available liquidity, and inventory limits. DISCOUNT_CURVE_1D: computes the executable quote using base discount, annualized term rate, convexity, risk tier, inventory pressure, and liquidity-depth penalty. We also built ZubiDubiRouteExecutor, which is the onchain settlement layer. It receives candidate Aqua/SwapVM strategies from the solver, calls the router for quotes, checks deliverable maker liquidity as min(Aqua virtual balance, wallet balance, allowance), applies shared term-risk budget caps, sorts/fills routes, charges a DAO fee, and executes atomically. If the full route cannot be filled, the transaction does not partially settle. The instruction library and route executor are covered by Foundry invariant and fuzz tests proving discount never goes negative or above par, payout is monotonic in time to maturity, convex discount is always at least linear discount, maker payout never exceeds the minimum of wallet balance and allowance, routes settle atomically, fees are conserved, and no maker's liquidity is double counted across sibling strategies sharing a budget. The live Sepolia book includes multiple independent maker wallets, not just one maker publishing sibling strategies. We funded two additional maker EOAs and shipped six more live strategies across different receipt assets and payout tokens, all indexed as active on the subgraph, with the hosted solver actually routing a real request across three independently owned strategies at once. This proves genuine multi-maker competition and routing on real deployed contracts, not a single wallet simulating multiple counterparties. For demo assets, we deployed PT-style receipt contracts on Sepolia. These are real ERC20 receipt contracts backed by real Sepolia WETH, USDC, and LINK. Users can issue claims by depositing backing assets and later redeem after maturity. For production, the same flow maps to real delayed-redemption assets such as Pendle PTs, withdrawal receipts, vault claims, or bridge receipts. We used real Chainlink feeds and onchain ratio adapters for pricing, plus an optional Pyth adapter path for dual-oracle validation. We also added a mainnet-fork Pendle benchmark test using a real Pendle PT market, so we can compare ZubiDubi's maker curve against Pendle's implied PT pricing and show inventory-aware repricing after maker exposure changes. The Graph is the market reconstruction layer. Our deployed Subgraph Studio endpoint indexes Aqua strategies, SwapVM fills, routed fills, skipped makers, shared term-risk budgets, receipt issuance/redemption, maker exposure, market volume, and DAO fee accrual. This lets the solver and frontend discover the live term-liquidity book without scanning raw logs. The solver API is a hosted Node service on Railway. It queries The Graph for active strategies, decodes executable SwapVM order bytes, calls Sepolia RPC for fresh quoteExactIn checks, returns route splits and budget-pressure metadata, and builds maker strategy payloads for the frontend. The frontend is deployed on Vercel and uses Privy for wallet connection, Viem for contract calls, The Graph for indexed state, and the Railway solver API for executable quotes. The frontend includes live markets, a swap-style sell page, maker strategy creation with an interactive curve editor where makers drag discount, cap, convexity, and exposure handles directly on the chart, backed by the same pricing math used onchain so the chart and the shipped transaction can never drift apart, portfolio issuance/redemption, and a playground page with proof panels, route-split visualizations, pressure-budget badges, test commands, and live Graph-backed state. Everything is deployed: verified Sepolia contracts, Graph subgraph, Railway solver API, and Vercel frontend.