Simulation versus broker
Keep simulator assumptions and broker execution responsibilities explicit.
Historical simulation and broker-backed execution share strategy concepts, but they do not provide identical order behavior. Record the execution runtime with every comparison.
Compare responsibilities
| Concern | Generic shared simulator | Broker-backed runtime |
|---|---|---|
| Fill price | Eligible quote close | Broker/venue execution updates |
| Delay | Configured delay measured in session market time | Submission, network, and venue processing |
| Price path | Close-based checks, no inferred intrabar path | Broker-specific trigger and matching behavior |
| Fill quantity | No volume-based partial-fill process | Adapter and broker report execution quantities |
| Capital | Simplified close × quantity check | Broker/account rules |
| Modification | Shared object replacement with matching rules | Adapter-specific; not implemented in every path |
| Completion evidence | Updated simulated orders, positions, and records | Acknowledgments plus subsequent reported state |
Known accounting limits
Shared same-side fills increase position quantity without establishing a fully weighted average entry basis. Partial-close accounting also uses simplified position-cost calculations. Avoid treating these paths as exact broker accounting for scaling strategies.
The walkthrough deliberately uses one unit and a full close so readers can inspect a small, explainable sequence. That example's simplicity does not remove other simulation assumptions.
Verify the selected adapter
Verify the selected broker's supported order operations. Simulator behavior does not establish broker modification support.
Similarly, retry, cancellation, order identifiers, and reported state must be interpreted through the actual adapter. A common TypeScript method signature is not evidence of identical lifecycle semantics.
Use historical runs for what they establish
A historical run can demonstrate how source and supplied observations produce requests under its configured rules. It cannot establish exchange priority, guaranteed live fills, or identical account behavior.
Before evaluating a broker-backed workflow, verify its instrument mapping, order support, source controls, and state reporting. Continue with debugging.