Polymarket Copy Trading Bot: How Polybuild Automates It
A copy trading bot is conceptually simple: watch a wallet, mirror its trades. In practice, the gap between "it works in a demo" and "it works on 500 live wallets 24/7" is mostly engineering. Here's how Polybuild's copy trading pipeline is built.
The pipeline in four stages
- Event ingestion — subscribe to on-chain trade events on Polygon for tracked wallets
- Signal extraction — decode the CLOB fill, map it to a Polymarket condition/outcome
- Sizing and risk — scale the trade to the copier's configured size, apply guardrails
- Execution — sign and submit a CLOB order from the copier's proxy wallet
Why latency matters more than you'd expect
Polymarket's orderbook is shallow on anything outside top-10 markets. If the trader you're copying takes 200 contracts at 43¢, and you're 15 seconds behind, the book may have walked to 46¢. A 3¢ slippage on a binary outcome is the difference between a profitable copy and a losing one.
Polybuild runs its event worker in Brazil (gru1) to stay inside Polymarket's supported geography while minimizing RPC hop count. The execution path — from event received to order signed — averages under 2 seconds.
Handling the weird cases
Real-world copy trading is mostly edge cases. What if the source wallet places a limit order that fills 3 hours later? What if they partially close a position? What if the market resolves while a copy order is in flight? Each case needs explicit handling — skip, partial mirror, cancel-and-retry — or the bot silently drifts from the source wallet's state.
Polybuild's worker maintains a running reconciliation between source position and copier position, so drift is detected and corrected rather than accumulating.
Non-custodial execution
The bot never holds funds. Each user has a proxy wallet; orders are signed using a key the user controls, and the worker only has permission to place orders within configured parameters. Withdrawals require the user's signature — the worker can't move USDC off the proxy.