# How Pregame works

> Pregame is market-maker software for Polymarket parlays. Bettors request parlay prices (RFQs) on Polymarket; your automated pricing engine quotes them inside rules you set; you collect the stake up front and keep it unless every leg of the parlay hits. This page explains the whole machine in plain terms, with worked examples.

Canonical URL: https://pre.game/how-it-works · Site index for agents: https://pre.game/llms.txt

## The one-sentence version

**You run a tiny automated sportsbook.** When someone on Polymarket wants to bet a parlay, your pricing engine offers them a price that includes your profit margin. If they take it, you collect their stake and pay out only if **every leg** of their parlay hits.

You never pick teams and never bet. You set the rules — how much margin to charge, how much money to risk, which games to touch — and the engine does the quoting automatically, around the clock.

## Two sides of every ticket

Every parlay has a bettor side and a house side. The bettor risks a little to win a lot; the house collects a little and risks a lot — on that one ticket. The house takes that trade all day because parlays rarely hit, and the price of every ticket includes margin.

**Example — one ticket, both sides (real numbers from a real Pregame fill):**

| | |
|---|---|
| Bettor stakes | $10 on a 4-leg parlay |
| If all 4 legs hit, bettor collects | $68.54 |
| House collects now | $10.00 |
| House pays out only if all 4 hit | $68.54 |

If ANY single leg misses, the ticket dies and the $10 is the house's. (One leg missed that night. The house kept the stake.)

## Where the parlays come from

Polymarket runs a system called **Combos RFQ** — Request For Quote. When a bettor builds a parlay (say, three baseball moneylines), Polymarket broadcasts the request to every connected market maker: "who will price this?"

Every maker has **400 milliseconds** to answer with a signed, binding price. The bettor sees the best one. That request stream runs all day — thousands of parlays per hour on a busy slate — and your engine listens to every single one.

Why speed matters: 400ms is faster than a human can read the request. That is why Pregame exists — no human is ever in the quoting loop. You write policy; the engine does the racing.

## The 400-millisecond quote

When a request arrives, your engine runs one pipeline, every time:

1. **Check your rules.** Right sport? Games and teams you allow? Leg count inside your band? If anything says no, it skips — skipping is always free.
2. **Price the legs.** It reads the live Polymarket market for each leg and multiplies the probabilities into a combined **fair value**.
3. **Add your margin.** Your pricing policy widens fair value into your quote.
4. **Size it.** The quote is capped by your per-ticket limit, your open-exposure limit, and your per-team caps — big requests get sized down, never stretched.
5. **Sign and send.** A cryptographically signed quote goes back. If the bettor takes it, the trade settles on-chain automatically.

**Example — one quote, start to finish (a real ticket from the live desk):**

| | |
|---|---|
| Request arrives | 4 legs, $10 notional |
| Legs priced from live markets | 62.5¢ × 58.5¢ × 60.5¢ × 62.5¢ |
| Fair value (multiplied) | 13.83¢ |
| Margin added | +5.5% |
| Quote sent | 14.59¢, in 155ms |
| Result | Filled. $10.00 collected, $58.54 at risk |

## Pricing: fair value plus your margin

**Fair value** is what the parlay is mathematically worth if the legs are independent — just the leg probabilities multiplied. Quote exactly fair and you make nothing; the margin is the business.

Pregame gives you two pricing modes and every dial in between:

- **Follow the market.** The engine watches what winning quotes actually charge, per leg count, over the last 24 hours — and prices at a percentage of that you choose. Set 90% and you undercut the going rate; set 110% and you price above it.
- **My prices.** Type your own margin for each leg count: say 300 bps on 2-leg tickets, 900 bps on 5-leg tickets. (100 bps = 1%.)

On top of either mode you can set a **floor** (never quote closer to fair than X), charge **extra on specific teams**, or **pin any single market** to a price you believe more than the market does.

**Example — the same 3-leg parlay under three policies (fair value 21.6¢):**

| Policy | Quote |
|---|---|
| Follow market @ 90% (market clears +5%) | 22.6¢ |
| My prices: 800 bps flat | 23.3¢ |
| With +200 bps extra on Yankees parlays | 23.8¢ |

Wider margin = more per fill, fewer fills. The dial is yours.

## Why the house side wins over time

One ticket is a gamble. A **book** of tickets is a business. Two forces work for you:

- **Margin on every ticket.** Every quote is priced above fair value, so across many tickets the average outcome tilts your way — the same reason casinos and sportsbooks are profitable without predicting anything.
- **Margin compounds with legs.** A little edge on each leg multiplies: modest per-leg margin becomes 8–15% on a 4-leg and more beyond. That is why parlays are the most profitable product in sports betting.

**Example — 100 tickets, toy numbers:** collect 100 × $10 = +$1,000. True hit rate at fair value is 13.8% (~14 winners expected); your price implied 14.6% (you charged for ~15). About 14 payouts × $68.54 ≈ −$960. Expected profit ≈ your margin × volume. Any single night can lose; the average is priced to win.

Honest version: variance is real. A night where favorites all win pays out many tickets at once. That is what the risk rails are for — capping how bad any one night can be.

## What you collect, and what you put at risk

When a quote fills, two things happen instantly, on-chain:

- The bettor's stake lands in your wallet — **the premium, collected up front**.
- Your wallet locks **collateral** for the worst case: the payout minus the stake. That is your **at-risk** on the ticket.

Settlement is automatic. When the games finish, the ticket resolves on-chain: if any leg missed, your collateral unlocks and the stake was pure margin; if every leg hit, the payout comes from that collateral. Winnings sweep back to your wallet without you touching anything.

**Example — a fill, in wallet terms (a real night, fees included):** $510.00 on hand → fill collects +$10.00 stake, locks $58.54 collateral → a leg misses, collateral unlocks → $519.59 on hand, up $9.59.

You can never quote money the wallet does not hold. Solvency is enforced in code.

## When the bettor wins

Sometimes every leg hits, and you pay — that is the product working, not breaking. Your margin priced that outcome in: winners are (slightly) rarer than the odds you charged for.

What actually protects you is never being too exposed to one outcome:

- **Per-ticket cap** — no single ticket can risk more than your number.
- **Per-team caps** — tickets that share a team win together; cap any team's total at-risk so a hot Yankees night cannot stack losses.
- **Open-exposure cap** — a ceiling on worst-case payout across every open ticket combined.

**Example — a losing ticket:** collect +$25 on a 3-leg; all three legs hit; pay out $180; net −$155 on the ticket — while the other 40 tickets that night booked +$212 of margin. Books lose tickets and win nights. Caps make sure no ticket can outweigh the night.

## Your rules, your book

Every number on the desk is yours to set, to the cent — Pregame recommends, never overrides:

- **What to quote:** sports, individual games, individual teams, even a single Over/Under market — each has its own on/off switch.
- **Size:** per-ticket cap, total open exposure, fills per day, per-team dollar caps.
- **Price:** pricing mode, undercut percentage, margin floor, per-team bumps, per-market pins and skews.
- **Selectivity:** leg-count band (2–6 leg tickets only, say) and a fair-price band (skip extreme longshots).

**Example — a cautious first book:** $25 max per ticket · $150 open exposure · 5 fills/day · MLB only, 2–4 legs, no longshots under 5¢. Worst possible day: bounded at $150.

## The safety rails

Underneath your rules sit protections that are not settings — they are physics, enforced in code:

- **Solvency.** The engine can never put more at risk than the wallet holds. Ever.
- **Fail closed.** Any ambiguity — stale price data, a market moving too fast, a leg it cannot identify — resolves to *not quoting*. A missed quote costs nothing; a bad quote costs money.
- **Circuit breakers.** Error storms, accounting mismatches, or suspicious patterns halt the desk automatically and tell you why, in plain language.
- **No correlated pricing.** Two legs from the same game are not independent, so the engine refuses to price them as if they were — a classic way naive makers get picked off.

## Watch first, then arm

You never have to start with money on. The Floor — Pregame's live console — runs in **watch mode**: you see the real request flow, what the engine *would* quote under your rules, and what the market is charging, with zero risk.

When the numbers make sense to you, arming the desk is one switch. Stopping is the same switch, and it acts within a second.

## Glossary

- **RFQ (Request For Quote)** — a bettor's parlay, broadcast to market makers for pricing. The start of everything.
- **Leg** — one bet inside a parlay: a moneyline, an Over/Under. All legs must hit for the parlay to pay.
- **Fair value** — the parlay's mathematical worth: the leg probabilities multiplied together.
- **Margin / edge** — how far above fair value you quote. Measured in basis points: 100 bps = 1%.
- **Fill** — a bettor accepted your quote. You collected the stake; the ticket is live.
- **At-risk** — the collateral a ticket locks: worst-case payout minus the stake you collected.
- **Premium** — the stake you collect up front, yours to keep unless every leg hits.
- **The book** — all your open tickets, viewed as one portfolio of risk and margin.
