arXiv:2611.08701cs.LGNov 2026

Manuscript Offprint

arXiv:2611.08701

Does a Trading Policy Need to Know What It Trades? Microstructure Invariance and Zero-Shot Transfer of Execution Policies

Hieu Tran, Hong Yu

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original. This text is shared under the same licence.

Abstract

Execution algorithms are calibrated asset by asset, because the queues, trade rates and bid-ask spreads they face differ by orders of magnitude across assets. For reinforcement learning this is zero-shot generalisation across contexts of very different scales, and microstructure invariance proposes a normalisation fixed by theory: measured in each asset's own units of time, size and price, markets look alike. In an exact order-by-order replay of public Nasdaq data, we train policies once, on 954 stocks in 2019, to choose between waiting in the queue and crossing the spread, and evaluate them unchanged on 1,964 unseen stocks in 2020–21, 2,629 stocks in 2025–26, crypto pairs and a second exchange. First, a policy that sees a stock only through its recent trade rate, trade size, spread and price increment (tick) costs within 0.015 spreads per share (a fifth of what learning saves) of a policy whose training data included the stock, and the stock's own history does not help it; it comes within a similar margin of policies trained on the second exchange when every episode counts equally, and within a wider one on crypto. Second, in mean cost before fees, invariant units beat raw units, z-scores and asset descriptors, but by under a basis point: most of their advantage is information and a common cost scale that a learner can also take as plain inputs, and none of the representations tested extrapolates to unseen spread regimes. Third, a near-zero transfer gap to a pooled comparator is weak evidence that a representation is right: we show that such a comparator detects only a small share of what a poor representation loses, and confirm it in synthetic markets and on pendulums.

1 Introduction

Every execution algorithm keeps facing the same small decision: rest a limit order at the best price and wait in the queue for a counterparty, or cross the spread, the gap between the best buy and sell prices, by trading now against the best opposite order (Figure 1a). Waiting saves the spread if the order fills and costs more if the price moves away (Cartea et al., 2015; Bouchaud et al., 2018). When to give up depends on the queue ahead, the rate at which trades arrive, the spread and the volatility, and these differ by orders of magnitude across assets. Execution policies, hand-tuned or learned, are therefore calibrated asset by asset, and reinforcement learning for execution and market making has mostly been trained and tested on one asset or a handful (Nevmyvaka et al., 2006; Spooner et al., 2018; Hambly et al., 2023). A per-asset policy needs per-asset data, has nothing to offer a new listing, and does not reveal which properties of an asset it depends on.

Microstructure invariance offers a different starting point: markets look alike once time, size and price are measured in units set by each asset's own trading. Kyle & Obizhaeva (2016b) derive these units from the asset's price, volume and volatility, Benzaquen et al. (2016) from its rate of trades, trade size and spread.

(a) Wait in the queue or cross the spread?

Figure

(b) Fill probability in seconds

Figure

(c) ...in the stock's own time

(d) Train once on 2019 Nasdaq stocks; test zero-shot on unseen stocks, later years, crypto and another exchange

Figure

Figure 1: One policy for every asset? (a) The decision we study: a buy order resting at the best bid can wait or cross the spread. (b, c) Why units might suffice: the probability that a 100-share order joining the best bid fills within a horizon varies widely across 1,189 training stock-days when time is in seconds, and far less in each stock's own mean time between trades (thick lines: medians within terciles of the relative tick, the price increment over the volatility per trade). (d) The test: policies trained once on 2019 Nasdaq stocks are evaluated unchanged on orange days; comparators trained on the test market use the grey days.

Figure 1b–c shows the idea on our data: the probability that an order at the best price fills within a horizon varies widely across stocks in seconds, and far less in each stock's own mean time between trades. Both theories have been tested on statistics of trades and costs. We test them on decisions. For reinforcement learning, this is zero-shot generalisation across contexts (Kirk et al., 2023): the assets are contexts whose scales of time, size and price differ by orders of magnitude, and invariance supplies a normalisation of observations and rewards, fixed by theory, under which they would become one task.

If two assets are statistically similar in some units, the optimal execution policy written in those units is the same for both (Proposition 1). Real stocks are never exactly similar, so we test the prediction empirically. We replay every order of the public Nasdaq sample days of 2019–2026 with queue position and latency 1^{1}, train one learner on eleven state representations, from raw physical units through standard normalisations to two families of invariant units (and two diagnostic variants), and evaluate the policies zero-shot on held-out stocks, later years, crypto pairs and a second exchange, whose last ten test days had not yet occurred when the policies were frozen (Figure 1d). We ask:

Q1. Does a policy trained on some stocks execute unseen stocks, and stocks six years later, as well as a policy that saw them? (Section 6.1)

Q2. What do invariant units supply that other representations lack? (Section 6.2)

Q3. Does the transfer reach another market and another exchange? (Section 6.3)

Q4. Is a small transfer gap evidence that a representation is right? (Section 6.4)

1^{1}Code: https://anonymous.4open.science/r/invex-6E30.

References (84)