The relevant model predicts the consequences of actions: next states, rewards, or both. A neural network estimating an action's value is not, by that fact alone, an environment model. Nor does training a model-free algorithm inside a simulator automatically change that algorithm into a model-based one.
What the model adds
Planning uses those predicted consequences to compare actions or improve a policy. It can happen when selecting an action, or during training so that a learned policy can later act quickly. A supplied, fixed model can support planning; the distinctive learning loop here is to improve an environment model from experience and use it to improve decisions.
A planner can be right about the wrong environment
For a finite next-state set, a one-step lookahead score is
Here is the model's expected immediate reward, its transition distribution, and a supplied continuation-value estimate. The Bellman equation motivates this immediate-reward-plus-continuation structure. One backup with an arbitrary is not a claim to have found optimal action values. The discount weights later rewards; it need not be a market interest-rate discount.
| Input | A | B |
|---|---|---|
| Immediate reward | 0 | 1 |
| Model probability of good | 0.8 | 0.6 |
| Stipulated environment probability of good | 0.4 | 0.6 |
Each bad-state probability is one minus its good-state probability. Assume the immediate rewards and continuation values are correct, so the only error is A's transition probability. Under the model,
More exhaustive planning with the unchanged wrong model would not fix this ranking. It could make the planner more confident about exploiting it. This is a decision problem caused by model bias, rather than a numerical optimisation failure.
How much imagination to trust
Long simulated trajectories can compound prediction errors. A policy update can also move the agent into states and actions poorly represented in the model's training data. Low average prediction error on historical data therefore does not establish reliable values for the actions a planner will select.
For execution research, three model choices deserve particular attention:
- Action effects. Fills and market impact must depend on the proposed order. Historical replay alone does not reveal what would have happened after a different, larger order.
- Changing conditions. Spread, liquidity and participant behaviour can change. A model calibrated on one period can misprice the consequences of actions in another.
- The objective and constraints. Rewards should reflect the specified transaction costs, inventory risk and unfinished-order treatment. Hard position or participation limits should restrict allowed actions. An accurate transition model cannot repair a reward that rewards the wrong behaviour.
Evaluate the complete model-and-policy procedure on separate later periods using decision-time information and explicit cost assumptions, comparing it with credible simpler rules. Repeatedly adjusting the model or reward after seeing those results creates backtest overfitting. A high simulated score is evidence about the model-and-policy combination under its assumptions; it is not evidence that the model has captured every market response.
Sources
- Sutton, R. S. (1990), Integrated Architectures for Learning, Planning, and Reacting Based on Approximating Dynamic Programming, ICML, pp.216–224. Original abstract read for the Dyna architecture and its integration of learned models and planning.
- Sutton, R. S. and Barto, A. G., Reinforcement Learning: An Introduction, local “Second edition, in progress” text, ©2014, 2015, §§8.1–8.2, pp.195–201. Read for distribution versus sample models, planning, direct learning and the Dyna-Q loop. This is a prepublication version.
- Janner, M., Fu, J., Zhang, M. and Levine, S. (2019), When to Trust Your Model: Model-Based Policy Optimization, NeurIPS, §§3–5 and §6.2. Read for model exploitation, distribution shift and short branched rollouts.
- López de Prado, M. (2018), Advances in Financial Machine Learning, §§11.2–11.4. Read for historical simulation, timing, costs and selection limits. The two-action illustration and execution interpretation here are original.