Welcome to Agents Academy

Module 17 · Production · ~12 min

Cross-venue market making.

By the end of this module, your agent will quote both sides of a market on Limitless and stay market-neutral by hedging every fill on a second venue, earning the spread between two books instead of betting on direction. It is the reference production agent: real, running, and watched through the operator panel you met in Module 02.

To get there, you’ll run the agents-starter cross-market-mm strategy, a cross-venue delta-neutral market maker, and lean on everything you just built: deploy it (Module 11), watch its decisions (Module 12), and trust the kill switch (Module 14). This module is the worked example. The runnable steps are canonical in the repo, so you will link out to them, not copy them here.

Production tier · Reference card
Quick answer

How does a cross-venue market-making agent work?

It quotes both sides of a Limitless market and hedges every fill on the matching Polymarket market, keeping the net position near flat, so it earns the spread between two books instead of betting on direction. The reference implementation is cross-market-mm in the agents-starter repo: quote, get filled, hedge on the other venue, record, check the breaker, one pass of the agent. The edge is the cross-venue spread plus fee-free maker activity on Limitless, with maker rebates and LP rewards as upside rather than the base case; the costs are the Polymarket spread every hedge crosses and adverse selection on your fills. The two markets must resolve on identical criteria (same entity, threshold, time, and source) or the hedge does the opposite of its job. The agent emits a flat-file contract (quotes.json, positions.json, fills.ndjson, kill.flag) that the operator panel and Telegram dashboard render live; the runnable commands stay canonical in the repo.

Commands, addresses, and flags live in the repo, not here.

Section 01

The strategy.

A market maker quotes both sides of a book and earns the spread when others trade against the quotes. The risk is inventory: every fill leaves you holding a position. The cross-market-mm agent removes that risk by hedging each fill on a second venue. It quotes a Limitless market and, the moment a quote fills, buys the opposite exposure on the matching Polymarket market. Net position stays near flat, so you are paid for providing liquidity, not for guessing direction. Read the loop as one pass of the agent.

  ┌─────────────────────┐
  │  quote both sides   │   Module 07: quote near the Polymarket book on Limitless
  └──────────┬──────────┘
             │  someone takes a quote
             ▼
  ┌─────────────────────┐
  │  fill on Limitless  │   you now hold inventory (net != 0)
  └──────────┬──────────┘
             │
             ▼
  ┌─────────────────────┐
  │ hedge on Polymarket │   buy the opposite side to return to flat
  └──────────┬──────────┘
             │
             ▼
  ┌─────────────────────┐
  │ record + emit panel │   Module 12: quotes.json, positions.json, fills.ndjson
  └──────────┬──────────┘
             │
             ▼
  ┌─────────────────────┐
  │ breaker / kill.flag │   Module 14: halt + flatten if drawdown or operator says stop
  └─────────────────────┘

The two markets must resolve on identical criteria (same entity, threshold, time, and source) or the hedge does the opposite of its job. The repo’s pair finder gates on liquidity and flags polarity mismatches, but you verify equivalence by hand before going live.

Section 02

Economics.

Two things to know before you quote a market: where the edge comes from, and what it costs. That is enough to tell a good pair from a bad one.

The edge

The cross-venue spread you capture each round trip, and maker activity on Limitless is fee-free. Maker rebates and LP rewards can add to that as upside; treat them as upside, not the base case, since eligibility and payout change.

The cost, and the constraint

The hedge crosses the Polymarket spread, and a fill often means a sharper counterparty took your quote (adverse selection). Both shrink the edge, so fill rate is the lever: short-window markets with real two-sided flow tend to work better than far-dated “winner” markets, which are liquid but slow.

Pitfall: the un-hedgeable dust fill

Polymarket rejects orders below a minimum notional (about $1). If a fill is small and the hedge price is low, the hedge can fall under that floor and silently skip, leaving you with un-hedged inventory you did not choose. Size orders so a full fill always clears the hedge floor on both sides, and run the repo’s preflight, which fails when order_size × price is too small to hedge. Watch the panel’s net-delta column: a pair that stays non-zero is the tell.

Section 03

Run it.

You already know this shape from Module 09 and Module 11: clone agents-starter, fill .env with a dedicated wallet, fund both venues, then gate on preflight before anything goes live. The commands live in the repo so they never drift from the code. Start in dry-run, every time.

The path (all canonical in the repo)

  1. Install + init, then fund the dedicated wallet on both venues via the deposit bridge. → QUICKSTART
  2. Pick and verify a market pair (same resolution criteria, both venues). → the repo’s find-pairs
  3. Run preflight: auth, funding, approvals, and the dust hedge guard must all pass. → AGENTS.md
  4. Start in dry_run. Watch the panel render quotes and net delta. Going live is the operator’s deliberate flip, never automatic. → Module 11

The agent does not need a dashboard wired in; it emits a flat-file contract and the operator panel reads it. That is the seam from Module 02: the agent writes, the panel renders. These are the files it writes to its data/ dir.

# quotes.json: current two-sided quote board, per pair
[{ "slug": "...", "bid": { "price": 0.62 }, "ask": { "price": 0.63 },
   "net_inventory": 0, "state": "two_sided" }]

# positions.json: cross-venue net delta as positions
[{ "slug": "...", "side": "YES", "shares": 0, "mark": 0.5 }]

# fills.ndjson: append-only; a hedge fill, then a learning event
{ "ts": "...", "side": "YES", "price": 0.41, "shares": 9.9 }
{ "ts": "...", "event": "hedge_skip", "reason": "notional too small" }

# kill.flag: present means halted. The breaker writes it on a
# drawdown trip; the panel kill button writes it; the bot reads
# it every loop and stops. One halt path, two triggers.

Point the operator panel at this data/ dir (the env vars are in AGENTS.md) and it renders the live agent: quote board, net delta, fills, and a kill button. Same contract feeds the Telegram dashboard.

Section 04

Watch it, stop it.

A market maker runs around the clock, so the operator surface and the stop path matter more than the strategy code. You built both already: this agent just plugs into them.

Watch: the operator panel + Telegram

The panel renders quotes, per-pair net delta, fills, and P&L from the flat-file contract. The Telegram dashboard edits one live card in place and adds Pull and Kill buttons for your phone. → Module 02 + 12

Pause: pull.flag

Pull quoting without halting: the agent cancels resting quotes and stops placing new ones, while the hedger keeps managing existing inventory back to flat. Use it when a market gets weird but you are not ready to stop. → Module 14

Stop: the breaker and kill.flag are one path

A drawdown breaker writes kill.flag on trip; the panel and Telegram kill buttons write the same file; the agent reads it every loop and halts, then flattens both venues on the way out. A fresh start refuses to boot while the flag exists, so a tripped agent stays tripped until you clear it. → Module 14

Common questions

Cross-venue market making: what people ask

Each answer also ships invisibly as schema.org FAQ data for search engines and AI assistants. Tap a question to expand.

  1. How do you get the cross-market-mm agent running?
    Four steps, all canonical in the repo so they never drift from the code: install and init, then fund a dedicated wallet on both venues via the deposit bridge (the QUICKSTART covers this); pick and verify a market pair with find-pairs; run preflight, which must pass auth, funding, approvals, and the dust hedge guard (see AGENTS.md); then start in dry_run and watch the panel render quotes and net delta. Going live is the operator’s deliberate flip, never automatic.
  2. What files does the agent write for the operator panel?
    A flat-file contract in its data/ dir, so the panel renders the agent without any dashboard code in the bot: quotes.json (the current two-sided quote board per pair, with net_inventory and a state like two_sided), positions.json (cross-venue net delta expressed as positions), fills.ndjson (append-only fills plus learning events such as hedge_skip), and kill.flag (present means halted). The same contract feeds the Telegram dashboard, which adds Pull and Kill buttons for your phone.
  3. How do you verify a market pair before quoting it?
    Check that both markets resolve on identical criteria: same entity, same threshold, same time, same resolution source. If they differ, the hedge does the opposite of its job, you end up holding risk instead of cancelling it. The repo’s pair finder gates on liquidity and flags polarity mismatches, but equivalence is verified by hand before going live; that judgement is not delegated to the tool.
  4. What is the difference between pull.flag and kill.flag?
    pull.flag pauses quoting without halting: the agent cancels resting quotes and stops placing new ones while the hedger keeps managing existing inventory back to flat, useful when a market gets weird but you are not ready to stop. kill.flag is the hard stop: the agent halts and flattens both venues on the way out, and a fresh start refuses to boot while the flag exists, so a tripped agent stays tripped until you clear it.
  5. Where does the edge come from, and what eats it?
    The edge is the cross-venue spread you capture each round trip, helped by the fact that maker activity on Limitless is fee-free; maker rebates and LP rewards can add to it, but treat them as upside, not the base case, since eligibility and payout change. It leaks in two places: every hedge crosses the Polymarket spread, and adverse selection means fills skew toward sharper counterparties. Fill rate is the lever that decides whether capture beats those costs.

Module checklist

Five confirmations.

Tick each item once you’ve actually done it. The Continue button unlocks at 5/5.

Take it live

Provide liquidity on Limitless.

You’ve run a real market-making agent in dry-run, watched it, and stopped it. Going live is your call, small at first, with the breaker armed.

Start trading on Limitless

Agents Academy · complete

You ran a real one.

Your agent provides liquidity and hedges itself flat, around the clock. Not a toy loop: a cross-venue market maker that quotes, hedges, records, and pulls its own plug, watched through the same operator panel and kill switch you built earlier in the tier.

Concretely, you took the abstract Production primitives, deploy, monitor, kill, and saw them carry a real strategy. The agent is executable truth in agents-starter; this academy taught you the why and how to operate it.

01

A cross-venue delta-neutral market maker: quote on Limitless, hedge each fill on Polymarket, stay near flat. Edge from the cross-venue spread and fee-free maker activity, with rebates and LP rewards as upside, not the base case.

02

An agent that emits a flat-file contract (quotes.json, positions.json, fills.ndjson, kill.flag) so the operator panel and Telegram dashboard render it live without any dashboard code in the bot.

03

One halt path with two triggers: a drawdown breaker and an operator kill button both write kill.flag; the agent reads it every loop, halts, and flattens both venues. Plus a pull switch to pause quoting without stopping.

Quick recall

Without scrolling back, can you answer these?

Five questions on the cross-venue market-making agent. Click each to reveal, the test is whether you can answer first.

  1. Why does hedging on a second venue make a market maker direction-neutral?
    A quote that fills leaves you holding inventory, exposure to which way the market moves. Buying the opposite exposure on an equivalent market on the other venue cancels that position, so your net delta returns to about zero. You keep the spread you captured and carry no directional bet, as long as both markets resolve on identical criteria.
  2. The book stays flat all week but equity drifts down. Where did the money go?
    Flat does not mean free. Each hedge crosses the Polymarket spread (you take, you pay), and adverse selection means fills skew toward counterparties with a better read. If captured spread is smaller than hedge cost plus adverse selection, you bleed slowly while perfectly hedged. Rebates/rewards can offset this, but they are programs, not guarantees.
  3. Why are far-dated “winner” markets a poor place to start?
    They are liquid but slow. Fills come rarely, and when they do it is often someone taking a stale quote, so adverse selection dominates the thin spread. Short-window markets with genuine two-sided flow give more fills at spreads where maker rebates and capture actually add up. Fill rate is the binding constraint.
  4. A small fill leaves a pair showing non-zero net delta that never hedges. What happened?
    The hedge fell under Polymarket’s minimum notional (about $1) and was skipped, leaving un-hedged inventory. Prevention: size orders so a full fill clears the hedge floor on both fill directions, and run preflight, which fails when order_size × price is too small to hedge. The panel’s net-delta column surfaces it.
  5. The breaker trips at 3pm. Walk the path, and explain why the panel kill button uses the same one.
    On a drawdown trip the breaker writes kill.flag; the agent reads it on the next loop, halts placing, cancels resting orders, and flattens both venues. The panel and Telegram kill buttons write the same kill.flag, so the automatic breaker and the human button share one halt path, one thing to test, one thing to recover from. A fresh start refuses to boot while the flag exists.

Next up: the Limitless Academy hub has more academies and time-boxed programs to explore.

Complete the checklist above to unlock