Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.signalium.site/llms.txt

Use this file to discover all available pages before exploring further.

Source: packages/contracts/src/PredictionMarket.sol Each market is an EIP-1167 minimal-proxy clone of the implementation at 0xf348…BBe59.

Constants

uint256 constant FEE_BPS              = 100;     // 1% of every bet
uint256 constant BPS_DENOM            = 10_000;
uint256 constant MIN_BET              = 0.001 ether;
uint256 constant DISPUTE_WINDOW       = 24 hours;
uint256 constant PROTOCOL_YIELD_BPS   = 2_000;   // 20% of yield to protocol

State machine

Open → Resolving → Resolved
              └─→ Voided  (judge returned Invalid, OR creator voided after dispute window)

bet(side)

Forwards the post-fee stake to the configured treasury (or self-custodies if treasury == 0x0). Updates yesPool / noPool notional accounting and the user’s Position.

resolve(outcome, attestationHash)

Callable only by the configured resolver (the AIResolver). Sets the outcome, recalls all liquid funds from the Treasury, and snapshots the yield split — see Yield economics.

claim()

Pulls the user’s pro-rata share of notional + bettorsYieldShare from the market balance. Tracked via totalBettorsPaid so withdrawHouse can compute the protocol’s slice without overdrawing.

withdrawHouse()

Permissionless. Computes houseAvailable = balance − (totalBettorsCommit − totalBettorsPaid) and sends to IFactoryFeeRecipient(factory).feeRecipient(). Late inflows from delayed Gimo claims roll into this bucket.

pullFromTreasury()

Permissionless. After resolve, lets a keeper (or anyone) pull matured Treasury liquidity into the market. The yield snapshot has already been taken so this only affects the protocol’s house balance, never the bettor payout.