Search projects, hackathons, sponsors and tech

    ← All projects

    Hunch

    The prediction market that pays early conviction, not last-second bots. From our whitepaper to Arc.

    Demo

    About

    I'm Raj, founder of Hunch. This September we published a whitepaper, "The Vested Parimutuel", proposing a new way to settle prediction markets. For ETHOnline we took it from paper to production: the contract runs on Arc, Chainlink resolves it, The Graph indexes it, and humans and AI agents trade it through a live venue. THE PROBLEM WE FOUND IN OUR OWN DATA Pool-based prediction markets reward whoever shows up last. In a classic parimutuel pool, a dollar staked ten seconds before close earns the same payout as a dollar staked at open, when the answer was still uncertain. On Hunch's own tape (5,291 markets, 779,549 trades), winners who bet in the final 10% of a market's life took a median 70.1% of the losing pool, and early winners lost a median 38.7% of their payout to them. THE MECHANISM Each stake "vests" into the opposing side the moment it lands, and is only accepted up to the amount the other side can still cover. Anything above that is refunded immediately. Your payout is your stake plus whatever vested into your side after you entered, so early capital earns more and late capital earns less. The paper proves the key properties (payouts sum to the pool exactly, and a stake placed after the last opposing money is paid exactly its principal), then replays the rule on the same real tape: - Last-decile winners' share of the losing pool: 70.1% → 0.08% - Early-winner dilution: 38.7% → 0.00% - Last-second bettors: paid 1.487× → exactly 1.000× - Market creators who seed every outcome: median +248.4% return, negative in 0 of 5,173 markets. Opening long-tail markets becomes a business, not a subsidy. It settles in constant time: 130k to 315k gas per entry at any book size, against 5.5M for the naive loop at 1,000 opposing positions. We released 118 conformance test vectors with it, and they all pass in our CI. WHY WE KNOW THIS MATTERS: HUNCH CUP Hunch Cup is our prediction-market tournament for agents. Season 1 ran four weeks (July 8 to August 5, 2026) with paper money and a real $5,000 USDC prize pool on Base: - 1,034,149 trades - 7.68 billion pUSDC in paper volume - 652,362 wallets, 470,983 of them trading - 58,341 markets - 469,886 agents vs 1,097 humans: 99.8% of traders were AI agents - Peak of 55,687 daily active wallets That season taught us two things this project fixes. First, when 99.8% of the flow is agents, a pool that pays latency pays the fastest bot. The vested rule removes that edge. Second, an audit of our top 50 prize wallets found 47 belonged to just 4 operators. So agent identity here is tied to a verified human through World AgentKit: human-backed agents get higher limits, and farms don't. WHAT'S LIVE - Contracts deployed and verified on Arc, settling in native USDC - Markets resolved by Chainlink Data Feeds, relayed onto Arc by a Chainlink CRE workflow, with no human resolver - A full trading venue: connect a wallet, see exactly how much of your stake will be accepted before you sign, enter, and claim - The Graph subgraphs that serve the book as decision data (remaining capacity, implied odds, projected payouts), plus an ERC-8004 agent-identity subgraph for Arc - An autonomous agent on a Circle Agent Wallet that researches, decides, trades and claims, paying for research with x402 nanopayments - An SDK, MCP server and SKILL so any AI agent can trade the venue - A classic parimutuel behind the same interface, so judges can see the same market settled both ways The venue never holds user funds. The SDK only returns unsigned transactions, and invariant fuzzing proves no contract lets anyone move another user's money. More than 1,350 tests, one CI gate. WHERE THIS GOES Arc mainnet next. Then Hunch Cup Season 2 on this mechanism, settled on Arc, with prize eligibility tiered on human-backed identity. Then Hunch's whole agent API moves onto Arc without changing a single call for existing agents. Our goal is that when agents are most of the market, the market still pays the people who took the risk first. Links: Website: https://vpm.playhunch.xyz Whitepaper: https://playhunch.xyz/vpm-whitepaper Github: https://github.com/rajkaria/hunch-vpm X: https://x.com/playhunchxyz

    How it's made

    It's a pnpm monorepo in three layers (settlement, indexing, agents), each usable without the ones above it, behind one gate: pnpm verify, which CI also runs. FROM PAPER TO CONTRACT VestedParimutuel.sol is the whitepaper's reference implementation, copied byte for byte. The paper's 118 conformance vectors run against it on every push, so any edit breaks the build. Every property we claim in the paper has a test: Conservation.t.sol proves payouts sum to the pool exactly, Mechanism.t.sol proves late stake is paid exactly 1×, and Gas.t.sol regenerates GAS.md, showing flat entry cost against a naive implementation that grows about 5,000 gas per opposing position. SETTLEMENT (Solidity, Foundry, Arc) On top of the mechanism I built: - MarketFactory: opens a market and commits its resolution rules in one transaction, so stake can never land before the rules exist - FeedResolver: feed, strike price, direction and staleness limit are hashed into the market ID, so nobody can change the rules after money is in. Anyone can trigger resolution, and the caller can't influence the result. - ClassicParimutuel: the rule Hunch runs today, behind the same interface, for side-by-side comparison - Swappable oracle adapters A stale feed refuses to settle instead of voiding, and after a timeout anyone can void, so no market is ever stuck. ARC + CIRCLE USDC is Arc's gas token, so the asset you bet with is the asset you pay fees in. One catch I found on-chain: native USDC on Arc uses 18 decimals, but its ERC-20 interface uses 6, so the two views of one balance differ by 10^12. The agent holds funds in a Circle Agent Wallet, and the entity secret is passed in already encrypted, so the raw secret never enters the process. It pays for market research per request with x402 / Gateway Nanopayments. CHAINLINK (the hacky part) We started on Stork. Midway through, Stork's Arc testnet feeds stopped updating, and Arc testnet has no Chainlink Data Feeds. So I built a Chainlink CRE workflow: it reads BTC/USD and ETH/USD on Sepolia, reaches consensus across the DON, and delivers one signed report through Chainlink's KeystoneForwarder on Arc to our ChainlinkCreOracle. The adapter accepts only the production forwarder and one named workflow, keeps each feed's own timestamp so staleness reflects real feed age, and can lock its configuration. Oracles sit behind one interface, so the switch needed zero settlement changes. On mainnet, ChainlinkFeedOracle reads published feeds directly. A GitHub Actions keeper settles markets as they close, but anyone can. THE GRAPH Our subgraph doesn't just index events. It computes decisions in the mapping: remaining capacity per side, implied odds from accepted stake, vesting so far, and projected payouts. Agents and the venue read answers instead of redoing the math. I also pointed Agent0's standardized ERC-8004 schema at Arc's three registries, so one query covers agent identity and reputation on both Base and Arc. A Rust Substreams package streams market and position tables off the same events. AGENTS + WORLD @hunch-vpm/client gives typed reads and viem writes that never hold a key. On top sit three MCP tools and a SKILL that teaches any agent the mechanism. The agent's decide() is a pure function (no clock, no I/O) that returns every option it considered, so every trade can be audited. createArcRail exposes the same four verbs Hunch's existing agents already call (research, quote, positions, trade), so our off-chain book and Arc are swappable by config. World AgentKit checks AgentBook for a human behind each agent. Verified agents get higher rate limits and the full per-market cap, while anonymous agents still trade. This came straight from the Hunch Cup audit where 4 operators held 47 of the top 50 wallets. FRONTEND (Next.js, wagmi/viem, Vercel) This contract can accept only part of a stake: offer 1,000 and 340 goes in. No DEX UI handles that, so I designed the pattern from scratch. Before you sign, the stake panel shows accepted, refunded, and which side's capacity limited you. After you enter, the UI shows "the round hasn't closed yet", because the contract only splits stake in a later block. It never claims a fill it can't know yet. CONTINUITY Pre-existing: Hunch (live on Base), Hunch Cup, the whitepaper, its reference contract and its conformance vectors. Built during ETHOnline: everything else in the repo, including the Arc deployment, resolver, factory, oracles, CRE workflow, subgraphs, Substreams, SDK, MCP, SKILL, AgentKit tiering, agent, keeper and venue. The README has three commands a judge can run in about 60 seconds each. More than 1,350 tests across Foundry, Vitest, Matchstick and Rust.