← prysm

Prysm: Permissionless Prediction Market Orderbooks

Abstract

Prysm is an open-source protocol for running permissionless prediction market orderbooks on Polymarket. It lets anyone operate a decentralized orderbook — posting, matching, and settling trades — without relying on Polymarket's centralized API or any single server operator.

The protocol ships as a TypeScript SDK paired with Solidity settlement contracts deployed on Polygon. Orders are signed client-side using EIP-712, encoded into a canonical wire format, and settled atomically on-chain through Polymarket's Conditional Token Framework (CTF). Every trade follows the split-share model: both sides post USDC collateral, the contract mints YES and NO outcome tokens via CTF.splitPosition(), and tokens are distributed to each counterparty — all in a single transaction. If any step fails, the entire settlement reverts.

Prysm solves four problems with existing prediction market infrastructure:

The protocol provides two settlement paths: an off-chain matching engine with atomic on-chain settlement via SettlementRouter, and a fully on-chain orderbook contract (PrysmOrderbook) for serverless operation where no centralized infrastructure is desired. Both paths use the same wire format, the same CTF integration, and the same atomic guarantees.

Prysm is designed to be embedded — by frontend teams building trading UIs, smart contract wallet integrators, and AI agent frameworks. The SDK is open-source (MIT). Alpha deployment targets the Polygon network.


Protocol: Prysm | SDK: `prysm-sdk` | License: MIT | Alpha chain: Polygon (137)