Protocol Documentation · Arbitrum Stylus
A Gaussian prices every outcome, and a closed-form curve pulls LP capital out of harm's way as the market approaches certainty. Scroll — the protocol explains itself.
How it works
01 — THE WIPEOUT
01 / 06
A prediction market sits at 95% YES. In a normal AMM every dollar of LP money is still tradeable, so the instant the event resolves, informed traders drain the winning side in a single block. The liquidity provider is left holding the worthless token. Not impermanent loss — permanent.
A standard AMM keeps 100% of LP capital tradeable — even at P = 0.95.
02 / 06
OMNIVERSE prices with a Gaussian invariant. The marginal price P = Φ((y−x)/L) is literally the market's probability of YES — the standard-normal CDF of the reserve imbalance, computed entirely on-chain.
03 / 06
The danger to LPs is a curve, not a constant. As price nears 0 or 1, the pool's price-sensitivity collapses and the adverse-selection cost weight γ_G(P) diverges. The edges are where LPs bleed.
04 / 06
So shield capital dynamically. Each block, OMNIVERSE splits reserves into an active fraction λ*(P) that trades and a passive fraction (1−λ*) that's hidden from informed flow. λ* is W-shaped — full near 50/50, collapsing toward the tails.
05 / 06
Watch a real attack. Three buys walk the probability 0.50 → 0.89. As it climbs the curve, the active fraction λ*(P) shrinks and the shielded share of LP capital climbs past half — automatically, with no oracle and no governance vote.
Live on Arbitrum Sepolia · market AI2030-DYN · three escalating buy orders.
06 / 06
The same Gaussian secures borrowing. If your collateral and your loan are tied to the same outcome, they fall to zero together when the event resolves against you. There is no price at which you get liquidated — the position simply nets out.
The protocol, in numbers
One curve carries the market; one closed-form λ* carries the defense. Everything else reduces to a handful of constants.
Φ
one Gaussian prices every outcome — P = Φ((y−x)/L)
W
λ*(P) is W-shaped: peaks at 0.16 / 0.84, collapses at the tails
73%
less LP exposure at the tail (P = 0.999) vs a constant policy
AR(1)
gap dynamics exact at all orders — variance ratio 1.001 ± 0.028
<$0.001
cost per block for the whole λ*(P) pipeline, in Rust/WASM on Arbitrum
0
oracles, and 0 liquidations in outcome-matched lending
07 / Try it
The same λ*(P) the Stylus kernel computes on-chain, live under your cursor. Drag P toward a tail and watch the shield grow.
active λ*(P)
42.7%
shielded (passive)
57.3%
Push P toward the tails and watch the shield grow — the same λ* the Stylus kernel computes on-chain for less than $0.001.
08 / The math
Everything the protocol believes, charges, and defends reduces to these.
The invariant
A Gaussian constant-function market maker. The marginal price is the event probability — no off-chain math, no oracle.
Optimal activeness
Closed-form λ*. W-shaped in P: maximal near 0.5, collapsing toward 0 as the market approaches certainty.
Why it diverges
The cost weight is endogenously probability-dependent: as P→0 or 1, φ(z)→0 and γ_G→∞, so λ*→0.
Three-layer defence
Time-decay × constant PA-AMM λ × Gaussian λ*(P). Each layer bounds a different timescale of LP loss.
09 / Two sides
The whole point: directional pressure moves the price, but the shield decides how much LP capital it can ever touch.
The attacker
The liquidity provider
10 / Lifecycle
Price, re-shield, settle, redeem — the loop every market runs.
solveSwap()
Price the trade
The Stylus kernel solves the Gaussian invariant for the output, against the active reserves only.
lambdaStar()
Re-shield
Each block λ*(P) re-partitions reserves into active and passive — automatically, no governance call.
resolve()
Settle on reality
The resolver records the observed outcome behind a dispute window. Trading halts.
redeem()
Pay out
Winning tokens redeem 1:1 against collateral; losing-side capital returns to LPs.
11 / Architecture
The Gaussian engine would be prohibitively expensive in Solidity. Stylus runs it as WASM for less than $0.001 a block.
The math kernel OmniverseMath is written in Rust, compiled to WASM via Arbitrum Stylus. It exposes φ, Φ, Φ⁻¹, λ* and a Newton-Raphson swap solver in 18-decimal fixed point.
The Solidity layer — factory, PA-AMM pool, ERC-1155 conditional tokens, and outcome-matched lending — calls into the kernel; a Ponder indexer streams every trade to this frontend.
MarketFactory.createEvent()
├─ PmAmmPool ──CALL──▶ OmniverseMath (WASM)
├─ ConditionalTokens (ERC-1155 YES / NO)
├─ MultiverseLending (outcome-matched)
├─ Resolver (dispute window)
└─ Ponder indexer ──GraphQL──▶ frontend
12 / The road ahead
Today the resolver is owner-controlled. Next: a panel of diverse models that debate, vote with calibrated weights, and abstain below a confidence threshold — handing the contract a single final price, never touching the math.
question → evidence → debate → weighted consensus
└─ if confidence ≥ τ: Resolver.setFinalPrice()
else: abstain → 24h dispute window keeps control
End of transmission
Market AI2030-DYN is live on Arbitrum Sepolia — push the probability and watch the shield defend the LPs in real time.