Glossary#
Terminology and definitions for the Seesaw protocol.
A#
Ask#
An offer to sell shares at a specified price. In Seesaw, all asks are stored as YES share asks in the canonical order book.
Atomic#
An operation that either fully succeeds or fully fails, with no partial state changes. All Seesaw instructions are atomic.
B#
Basis Point (bps)#
One hundredth of a percentage point. 100 bps = 1%, 10,000 bps = 100%. Seesaw uses basis points for all price representation.
Best Ask#
The lowest price at which someone is willing to sell. Represented as best_ask_price in the orderbook.
Best Bid#
The highest price at which someone is willing to buy. Represented as best_bid_price in the orderbook.
Bid#
An offer to buy shares at a specified price. In Seesaw, all bids are stored as YES share bids in the canonical order book.
Binary Market#
A market with exactly two possible outcomes. In Seesaw, these are UP (price increased) or DOWN (price decreased).
BPF (Berkeley Packet Filter)#
The virtual machine used by Solana to execute on-chain programs. Seesaw is compiled to BPF.
C#
Canonical Order Book#
The single internal representation of all orders as YES share orders. NO orders are converted to equivalent YES orders.
Collateral#
The USDC (or other settlement currency) locked to back positions. Full collateralization ensures the protocol can always pay out.
Confidence Interval#
The Pyth oracle's uncertainty range for a price. Markets may optionally reject prices with wide confidence intervals.
Crank#
A permissionless operation that advances protocol state, such as creating markets or capturing price snapshots. Anyone can run a crank.
Crossed Book#
An invalid state where the best bid is >= the best ask. Seesaw prevents this condition.
D#
Discriminator#
An 8-byte prefix that identifies the account type. Used to prevent account confusion attacks.
Dual-View Single Engine#
Seesaw's order book design where users see four order types (BuyYes, SellYes, BuyNo, SellNo) but internally all orders are stored as YES orders.
E#
Epoch#
A time window during which a single market operates. Durations are configurable from 60 seconds to 7 days (default: 15 minutes). Each epoch has a unique market ID.
Expiry#
The deadline after which a market can be force-closed if not properly resolved. Set to 7 days after the epoch ends.
F#
Fill#
A trade execution where a taker's order matches against a maker's resting order.
Force Close#
An emergency mechanism to close markets that are stuck. Available after the expiry window.
Full Collateralization#
The requirement that every share is backed by exactly 1 USDC in the vault. This ensures the protocol is always solvent.
G#
Governance#
The mechanism for updating protocol parameters. Currently controlled by protocol authority.
H#
Health Check#
A system to verify the protocol and crank infrastructure are operating correctly.
I#
Idempotency#
The property that an operation can be safely repeated without changing the result. All crank operations are idempotent.
Immediate-Or-Cancel (IOC)#
An order type that executes whatever quantity is possible immediately and cancels the remainder.
Invariant#
A condition that must always be true. Violating an invariant indicates a bug or attack.
K#
Keypair#
A public/private key pair used for signing transactions. Crank operators need a funded keypair.
L#
Limit Order#
An order that specifies a maximum buy price or minimum sell price. Unfilled portions rest on the order book.
Liquidity#
The availability of orders on the book. More liquidity means tighter spreads and better execution.
Locked Shares#
Shares committed to open sell orders. Locked shares cannot be sold again until the order is cancelled or filled.
Locked Collateral#
USDC committed to open buy orders. Locked collateral cannot be used for other orders.
M#
Maker#
A trader whose order rests on the order book before execution. Makers receive rebates.
Maker Rebate#
Deprecated in v2. In v1, makers received a 10 bps (0.1%) rebate on fills. In the current token architecture, makers pay zero fees and receive no rebate. The maker_rebate_bps field is retained at offset 162 in ConfigAccount for layout compatibility but is always 0.
Market#
A prediction market for a single epoch. Each market predicts whether the underlying asset's price will go UP or DOWN within its configured duration.
Market ID#
A unique identifier for a market, calculated as floor(unix_timestamp / duration_seconds). Example: 1892160 (for a 15-minute market).
Matching Engine#
The component that pairs buy and sell orders and executes trades.
Mid Price#
The average of the best bid and best ask. Used to estimate the market's implied probability.
N#
Naked Short#
Selling shares you don't own. Prohibited in Seesaw - you can only sell shares in your position.
NO Share#
A share that pays out 1 USDC if the market resolves to DOWN (price strictly decreased: P_end < P_start). Note: if the price is unchanged, the outcome is UP and YES shares win.
O#
Oracle#
An external data source providing price information. Seesaw uses Pyth Network exclusively.
Order Book#
A data structure that stores all open buy and sell orders, sorted by price.
Order ID#
A unique identifier for an order within a market's orderbook. Monotonically increasing.
Outcome#
The final result of a market: UP or DOWN. Determined by comparing end price to start price.
P#
PDA (Program Derived Address)#
A deterministic address derived from seeds and the program ID. PDAs can sign on behalf of the program.
Permissionless#
Operations that can be executed by anyone without special authorization.
Position#
A user's holdings in a specific market, including YES shares, NO shares, and locked amounts.
PostOnly Order#
An order that will only be placed if it doesn't immediately match. Rejected if it would cross the spread.
Price-Time Priority#
The matching rule where better prices match first, and at equal prices, earlier orders match first.
Protocol#
The Seesaw smart contract and its rules.
Pyth Network#
The decentralized oracle network providing price feeds for Seesaw markets.
Q#
Quantity#
The number of shares in an order or position.
R#
Rent#
Solana's fee for storing data on-chain. Accounts must be rent-exempt (hold enough SOL to cover 2 years of rent).
Resolution#
The process of determining a market's outcome based on the start and end price snapshots.
Resting Order#
An order that is sitting on the order book waiting to be filled.
S#
Sampling Rule#
The rule for which Pyth price to use for snapshots. Seesaw uses "first price with publish_time >= boundary."
Settlement#
The process of paying out winning positions after a market resolves.
Settlement Currency#
The token used for collateral and payouts. Default: USDC.
Snapshot#
A captured oracle price at a specific time boundary (start or end of epoch).
Solvency#
The property that the protocol can always pay all obligations. Ensured by full collateralization.
Spread#
The difference between the best bid and best ask. Tighter spreads indicate better liquidity.
State Machine#
The formal model of market states (PENDING, CREATED, TRADING, SETTLING, RESOLVED, CLOSED) and valid transitions.
T#
Taker#
A trader whose order matches immediately against resting orders. Takers pay fees.
Taker Fee#
A fee charged on the filled portion of taker orders. Default: 200 bps (2.0%), split between the protocol treasury (150 bps / 1.5%) and the market creator (50 bps / 0.5%).
Tick#
The minimum price increment for orders. Default: 100 bps (1%).
Tick Rounding#
The process of rounding order prices to valid tick levels. Bids round down, asks round up.
Trade#
An executed match between a bid and an ask.
Trading Window#
The time period during which orders can be placed. From start snapshot to end of epoch.
Treasury#
The protocol account that holds accumulated fees and funds crank rewards.
U#
UP#
The market outcome when end_price >= start_price. YES shares pay out.
V#
Vault#
The token account holding all collateral for a market. Owned by the market PDA.
W#
Wallet#
A user's Solana account holding their keypair. Used to sign transactions.
Wash Trading#
Trading with yourself to create fake volume. Prevented by self-trade prevention.
Y#
YES Share#
A share that pays out 1 USDC if the market resolves to UP (price increased).
Symbols and Formulas#
Price Conversion#
YES price + NO price = 10,000 bps (100%)
Buy YES @ p = Bid @ p (canonical)
Sell YES @ p = Ask @ p (canonical)
Buy NO @ q = Ask @ (10000-q) (canonical)
Sell NO @ q = Bid @ (10000-q) (canonical)
Market ID#
market_id = floor(unix_timestamp / duration_seconds)
t_start = market_id * duration_seconds
t_end = t_start + duration_seconds
Collateral#
collateral = price_bps * quantity / 10,000
Solvency Invariant#
vault_balance >= max(total_yes_shares, total_no_shares)
Fee Calculations#
taker_fee = ceiling(amount * taker_fee_bps / 10,000)
protocol_fee = ceiling(amount * protocol_fee_bps / 10,000)
creator_fee = taker_fee - protocol_fee
Abbreviations#
| Abbreviation | Meaning |
|---|---|
| BPF | Berkeley Packet Filter |
| bps | Basis points |
| CU | Compute units |
| IOC | Immediate-Or-Cancel |
| PDA | Program Derived Address |
| RPC | Remote Procedure Call |
| SOL | Solana's native token |
| SPL | Solana Program Library |
| USDC | USD Coin |
Next Steps#
- Review Error Codes for troubleshooting
- See Constants for protocol values