Definition
Two-leg execution refers to the coordinated placement of both legs of a cross-platform arbitrage trade. Leg 1 is the purchase on the first platform (e.g., YES on Polymarket). Leg 2 is the purchase on the second platform (e.g., NO on Kalshi). Both must fill at or near their expected prices for the arbitrage to work as planned.
Why simultaneity matters
Arbitrage windows close in 30–200 seconds. If you place Leg 1 and then manually place Leg 2, the spread may have already collapsed by the time Leg 2 executes. You're then holding a one-sided directional position — the opposite of what you intended. The faster both legs execute, the smaller the window for price movement between them.
The leg risk problem
Even with automation, there's always a small window between Leg 1 and Leg 2. If Leg 1 fills at the expected price but Leg 2 is rejected (price moved, insufficient liquidity), you're left with an open directional position. This is called leg risk, and it's the primary operational risk in prediction market arbitrage.
How Arbitrage Agent handles it
Arbitrage Agent fires both legs in parallel — not sequentially. Both API calls are initiated at the same time, reducing the inter-leg delay to network latency only. P99 fill latency is under 400ms. If Leg 2 fails to fill within a timeout, the circuit breaker automatically reverses Leg 1.
Limit vs market orders
For arbitrage, limit orders are preferred. They guarantee fill at or better than the calculated price, preserving the spread. Market orders on thin books can cause significant slippage, eliminating the edge or even creating a loss.