One operator approves a small live launch for an intraday trading agent. Another rejects the same strategy after replaying its orders against captured market data. Both have the same five-year backtest. The difference is what they count as evidence.
The example below uses a liquid US exchange-traded fund and a five-minute mean-reversion strategy. All figures are illustrative, not audited results. They show how backtesting versus forward testing can produce opposite calls even when the signal logic is unchanged.
Two operators, one strategy, opposite calls
The case for a limited launch
Operator A tests five years of point-in-time minute data and records 2,460 round trips. The backtest includes commissions and an assumed 1.4 basis points of spread and slippage per side. It reports a 1.18 Sharpe ratio, 4.8% annualised return and 5.2% maximum drawdown. A separate 20-session paper run records 184 entry signals, with 174 simulated fills.
A sees enough evidence to launch at 5% of the intended allocation, with a hard daily loss limit and a manual kill switch. The decision is cautious in size, but it treats the paper fills as confirmation that the historical edge can survive order submission.
The case against launch
Operator B inspects the order and market-data logs from those same paper sessions. Eleven signals arrived while the latest quote was more than 750 milliseconds old.
Seven corresponding orders would have been rejected or repriced under the broker's live price checks. Two retries reused a client order identifier after a connection reset, and the paper simulator filled several marketable limits near the mid-price.
B replays the signals against captured bid and ask data, applies a 2.5 basis point per-side cost assumption and accounts for missed fills. The estimated Sharpe falls to 0.42. B refuses the launch, not because the backtest is invalid, but because the tested agent did not reliably produce the orders the backtest assumes.
Both calls are understandable. A has evidence about historical signal performance. B has found unresolved execution and state-management faults. For unattended software, those are different questions and need separate gates.
Backtests and forward tests answer different questions
A backtest asks whether a strategy would have made money under a specified model of data, fills and costs. A forward test asks whether the running system behaves as expected on data arriving after the strategy is fixed. Neither test can stand in for the other.
For the historical test, preserve point-in-time inputs. Check that indicators use only data available at the decision timestamp, that corporate actions are handled consistently and that the test does not quietly remove delisted instruments. Use the next tradable quote or a documented fill model, not the signal bar's closing price by default. A one-minute bar cannot reveal whether a limit order sat behind a queue or whether the price moved before the order reached the venue.
Costs deserve their own sensitivity test. A liquid ETF can have a tight quoted spread in normal hours, but realised costs vary with order size, volatility, urgency and routing. Model commissions, exchange fees where relevant, spread crossing, slippage and partial fills separately. Then test what happens if the assumed slippage doubles. If a small cost change removes most of the edge, the result is fragile.
Forward testing covers a different set of faults: feed delays, clock differences, API limits, rejected orders, partial fills, reconnects and the gap between a simulated fill and a real queue. A paper broker may accept a syntactically valid order without modelling those conditions.
Record signal time, market-data time, order-send time, acknowledgement time, fill time and cancel time. Without these timestamps, a disappointing result is hard to diagnose.
The ranges below are typical planning ranges for liquid US large-cap intraday strategies, not universal thresholds. Shorter-horizon or less liquid strategies need different samples and cost assumptions.
| Test stage | Typical window | Typical observations | Typical cost evidence |
|---|---|---|---|
| Historical backtest | 2-5 years | 1,000-5,000 completed trades | Modelled 0.5-2.5 basis points per side |
| Market-data replay | 2-12 weeks of captured data | 500-10,000 quote or order events | Recorded spread, plus a slippage sensitivity range |
| Paper forward test | 4-12 weeks | 100-500 signals | Simulator fills compared with executable quotes |
| Live shadow mode | 2-8 weeks | 100-500 order intents | Estimated cost against contemporaneous bid and ask |
| Small live deployment | 2-8 weeks | 50-300 orders | Observed fills, often 0.5-4 basis points per side |
These sample counts can expose operational defects, but they do not prove a strategy has a durable edge. For example, zero incidents in 200 orders still leaves an approximate 95% upper bound of 1.5% on the underlying incident rate, using the rule of three. A clean paper month is evidence about that month's behaviour, not a guarantee about the next market regime.
Stage the test around the failure modes
Replay the order lifecycle, not just the signal
Build a replay harness that feeds recorded events into the same decision and order-management code used in production. Keep strategy parameters fixed before the forward window begins. If the agent can call tools or choose order types dynamically, log the inputs and outputs of each call as well as the resulting broker request.
Inject failures deliberately. Disconnect during an order acknowledgement. Return a partial fill, then a cancel acknowledgement. Delay a quote, exceed a rate limit and send a duplicate callback. Confirm that the agent reconciles its local position against broker state before placing another order. A timeout is not proof that an order failed; the broker may have accepted it while the response was lost.
For each order, persist a stable client identifier and a state transition record. Test idempotent retries, cancel-and-replace logic, maximum open orders, position limits and handling of late fills after a cancel request. Keep an independent risk layer able to block orders even if the strategy process loops or loses its internal state.
Use forward tests for live-system evidence
Run paper trading only after the replay tests pass. Compare simulated fills with the available bid and ask at the moment of execution, and report the difference by order type, time of day and volatility band. A fill-rate figure without that breakdown can conceal that the simulator fills passive orders which would rarely reach the front of a real queue.
Then run in shadow mode: the agent receives live data and creates order intents, but a separate control prevents submission. Compare its intended side, size, limit price and timing with the recorded market.
Platform choices belong in this test design, alongside the agentic trading platform landscape. The simulator's fill model still needs independent scrutiny.
Promote through explicit stages rather than treating a paper account as a rehearsal of live trading:
- Pass historical tests with point-in-time data, costs and out-of-sample periods.
- Pass event replay, including disconnects, partial fills, stale data and duplicate messages.
- Run paper and shadow tests long enough to collect the expected signal and order volume.
- Begin live with a small allocation, strict notional caps and a tested kill path.
Set gates before looking at the next result
Write pass conditions before forward testing starts. Otherwise, it is easy to explain away a bad fill or extend a test until the numbers look reassuring. Set operational gates separately from performance gates. The former can be binary; the latter need uncertainty bounds and a comparison with the assumptions in the backtest.
A practical gate sheet can include:
- Zero duplicate live orders during a defined replay and paper test set.
- All positions reconcile after restart, reconnect and partial-fill scenarios.
- At least 99% of order intents have complete timestamps and a traceable decision record.
- Observed or estimated execution costs remain within a pre-set range of the model, such as 20-30%.
- Daily loss, position and order-rate limits block requests at their configured thresholds.
- Any stale-feed or broker-state uncertainty pauses new orders and raises an alert.
Performance gates should account for sample size. Compare forward results with a range of expected outcomes, not a single backtest point estimate. Track net P&L, fill rate, slippage, rejection rate, turnover and drawdown. Keep the strategy unchanged during the test; a parameter adjustment creates a new version and needs its own evaluation.
When a system moves to small live size, increase allocation only after reviewing actual fills and operational incidents. A typical first live sample of 50-300 orders may reveal routing or state issues, but may be too small to distinguish modest strategy outperformance from noise. Keep live risk caps in place while gathering more evidence.
The mistake most readers will still make is treating a longer paper test as proof that simulated fills and unattended order handling are safe.
Frequently Asked Questions
How long should an agent strategy forward test run?
For a liquid intraday strategy, 4-12 weeks is a typical planning range, with enough signals to inspect fills and operational behaviour. Extend the test if it has not encountered relevant conditions, but do not treat elapsed time alone as proof of a trading edge.
How many trades are enough for forward testing?
A typical paper or shadow test may collect 100-500 signals or order intents. That can expose workflow faults, but small samples provide weak evidence about strategy profitability and rare failures.
Can paper trading replace a backtest?
No. Paper trading exercises a running system on new data, while a backtest evaluates a strategy across historical market conditions. Both need documented assumptions, and paper fills may not reproduce queue position, market impact or live broker behaviour.
What should be checked before moving a trading agent live?
Verify order idempotency, position reconciliation, partial-fill handling, stale-data pauses, rate limits and independent risk controls. Start with capped exposure and compare actual execution costs with the model before increasing size.