Resolution and Settlement
Resolution is the process of determining the outcome of an event, and settlement is the process of paying out (or zeroing) positions based on that outcome. Together, they are the final stage of every prediction market's lifecycle on Intotes.
Event Lifecycleβ
Every event moves through a defined set of states:
new --> started --> paid
| State | Description |
|---|---|
new | The event has been created and is open for trading. |
started | The real-world event has begun (e.g., a match kicked off). Trading may still be open depending on market configuration. |
paid | All positions have been settled and payouts distributed. |
Pool Lifecycleβ
Within an event, each pool follows its own lifecycle:
active --> closed (won_side set) --> settled
| State | Description |
|---|---|
active | The pool is live and its markets are open for trading. |
closed | The outcome has been determined. won_side is set. No further trades are accepted. |
settled | All positions in this pool have been paid out. |
Closing: Setting the Outcomeβ
When the real-world outcome is known, the event creator (or an admin) closes the market by setting the won_side:
won_side = 0means the first outcome won (e.g., YES in a binary market).won_side = 1means the second outcome won (e.g., NO).- For markets with more than two outcomes, higher indices correspond to additional outcomes.
Closing can be performed at different levels of granularity:
| Action | Effect |
|---|---|
| Close a market | Sets the outcome for a single market within a pool. |
| Close a pool | Sets the outcome for the entire pool and all its markets. |
| Close an event | Closes every pool in the event, resolving all markets at once. |
Once a pool is closed, all trading in that pool stops immediately.
Settlement: Paying Out Positionsβ
After a pool is closed and won_side is set, the system settles all open positions:
Payout Rulesβ
- YES holders: Receive 10,000 cents ($100.00) per share if the YES outcome wins. Receive 0 if YES loses.
- NO holders: Receive 10,000 cents ($100.00) per share if the NO outcome wins. Receive 0 if NO loses.
In other words, each share of the winning outcome pays out at the maximum value, and each share of the losing outcome expires worthless.
Exampleβ
Suppose a trader holds 5 YES shares that they bought at an average price of $0.60 each:
- If YES wins: Payout = 5 shares * $100.00 = $500.00
- If YES loses: Payout = $0.00
Profit and Loss Calculationβ
The PnL for a settled position is calculated as:
PnL = settlement_payout - (amount * avg_price / 10000)
Where:
settlement_payoutis the total amount received at settlement (in cents).amountis the number of shares held.avg_priceis the volume-weighted average price at which the shares were acquired (in cents).10000normalizes the price to the per-share payout basis.
Using the example above (5 YES shares at $0.60 avg, YES wins):
PnL = 50000 - (5 * 6000 / 10000)
PnL = 50000 - 3000
PnL = 47000 cents = $470.00 profit
If YES had lost:
PnL = 0 - (5 * 6000 / 10000)
PnL = -3000 cents = -$30.00 loss
ClosedPosition Recordβ
When settlement occurs, the system creates a ClosedPosition record for each user's position in the resolved market. This record includes:
| Field | Description |
|---|---|
pnl | The realized profit or loss from the position, in cents. |
won_side | The winning outcome index (0, 1, etc.) that was set at close. |
settlement_payout | The total payout received. |
amount | Number of shares that were held. |
avg_price | The average entry price of the position. |
won_side = nilβ
If won_side is nil (null) on a ClosedPosition record, it means the position was manually closed by the trader before the event was resolved -- not settled through the resolution process. In this case, the PnL reflects the trader's exit price rather than a settlement payout.
Cancelling an Eventβ
In exceptional circumstances, an event can be cancelled instead of resolved. When an event is cancelled:
- All open positions are refunded at their original cost. Every trader receives back exactly what they spent to acquire their shares.
- No winner is declared. No
won_sideis set on any pool. - The event moves to a terminal state and no further action can be taken.
Cancellation is a protective mechanism used when an event becomes invalid (e.g., a match is postponed indefinitely, the question becomes unanswerable, or there is a data integrity issue).