Glossary
Terms this library uses in one specific way. Where a number pins the meaning, the number is here.
ADV
the run
Average daily volume, the denominator for participation. 13.7 million shares is 0.05x a day in one name and 407x in another.
anchor_price
price formation
fundamental_value times exp(mispricing_s): what the model wanted before the book touched it. So close minus anchor_price isolates the microstructure.
Checkpoint and branch
the run
Two ways to fork a run at one state. On a 60-day 40-instrument run, branch copies engine state in under 1 ms and does not survive the process. Checkpoint replays the order log in 2.7 s and does.
circuit_breaker
price formation
Books the rewrite when the model price leaves the session band and the tick re-derives s from the clamped price. Omit the column and the factor sum misses that correction on any day the breaker binds.
close_market
the run
The day's close bookkeeping: momentum roll, GARCH, macro step. It advances the macro chain into the next day, so a row recorded after it carries the values the next day will trade under.
common random numbers
provenance
Running one seed under two presets so draws_consumed comes out identical. Every difference in the outcome is then a parameter effect rather than reshuffled noise.
crowd lean
price formation
The crowd net-buys what trades below fair value and net-sells what trades above it, capped at 0.02 in log price so the crowd can never dominate a news day.
draw schedule
provenance
Market hours, the 390-tick day, the calendar and the sector key order. Nothing settable may change it: a preset changes what the draws are multiplied into, never the schedule.
draw_delta
provenance
The market stream's draw-count difference between the two runs compare() puts side by side. Zero across all twenty-eight comparisons on pt-v14. Non-zero means a halt, a delisting or a roster change moved the schedule.
draws_consumed
provenance
Total draws from three of the seven streams: market, economy and external. Equal market counts between two runs of the same tick schedule mean both saw an identical noise sequence.
Engine
the run
A whole market stepped through time. It owns the seeded generator, the per-company price state, the economy and the central bank, and nothing beyond those four.
era boundary
provenance
A change that moves every seeded trajectory, caught by a probe digest rather than a version string. One calendar day once brought three trajectory-changing fixes while the version and the preset both stayed put.
era_fingerprint()
provenance
The digest of a small fixed probe simulation, recomputed before every replay. Two builds that agree on the probe agree on the arithmetic it exercises.
fair value
price formation
The level mean reversion pulls toward. It reprices at the central bank's meeting calendar, so a run long enough to cross a meeting is not a stationary experiment.
fingerprint, model
provenance
The first 8 hex characters of a sha256 over the preset's canonical serialisation. Any settable change reads custom-7f290e34 rather than pt-v1, so a changed preset can not present as the shipped one.
fingerprint, strategy
provenance
A sha256 over the spec, unchanged by whitespace, key order, or scaling every blend weight by two. Empty for a hand-built agent, because that result is reproducible only by citing code at a commit.
fingerprint, universe
provenance
A sha256 over the roster's canonical form, order included. AAA closes day 5 at 143.03 in roster order and 134.88 reversed.
fundamental_value
price formation
What the company is worth on its fundamentals, with no mispricing in it.
GJR-GARCH
price formation
The per-name variance recursion. garch_alpha on yesterday's squared return, garch_beta on yesterday's variance, plus a GJR garch_gamma that adds weight when that return was negative, because a symmetric GARCH squares the return and destroys its sign.
guards
price formation
The mispricing cap, the crowd lean cap, the session breaker and the price cap. Settable, and excluded from every calibration search because they are worst-case guarantees. daily_shock_cap is not settable at all.
idiosyncratic
price formation
The part of a name's return no other name shares: one normal per company per tick, sized by that name's own GARCH variance.
Instrument
the run
One tradable company: ticker, sector and eight fundamentals. short_interest is a share count, so a value between 0 and 1 raises rather than being read as a fraction.
jump
price formation
Applied to mispricing_s after the tick loop rather than inside it. Dropping it from the sum takes the worst residual from 1.9e-16 to 0.090 on a run carrying one jump row in 39,000.
known-answer test
provenance
One fixed simulation run inside each of five wheel targets and hashed, compared target against target and against the sha256 committed in tests/known_answer.json. A disagreement stops the upload.
Macro
the run
Day-zero rates, inflation and the cycle. The chain runs on from there by itself, so vix takes 118 distinct values over a 120-day run.
market factor
price formation
One normal drawn per tick that reaches every name through its beta. Without shared factors a 108-name index would have almost no aggregate volatility, because independent noise cancels.
market maker
the run
The counterparty on every book. It quotes both sides and shifts both quotes toward reducing its inventory, so the book absorbs one-sided flow without running dry.
mispricing_s
price formation
Log deviation of price from fair value. The nine factor columns sum to its change, with a worst residual of 1.9e-16 over 39,000 rows.
order book
the run
engine.book(ticker) returns a detached snapshot. Filling against it prices your execution at the levels you consume and leaves prices() byte-identical to the run that never traded.
order flow impact
price formation
The permanent, information share of order flow into mispricing_s: 0.35 of the total impact coefficient of 50.0. The book already charges the temporary component when orders walk the book's depth.
order log
the run
engine.order_log holds every input the engine consumed. An unknown entry raises on replay rather than being skipped, because a replay that ignored one would look like a success.
order_flow
the run
The channel that tells the market you traded, passed to tick() or run_session(). Pushing 500,000 AAA shares through it closes the name at 137.45 against 135.67 untouched.
random_noise
price formation
The market component times the crash amplifier, plus the sector component, plus the idiosyncratic draw, summed into one column. truth can not separate the three.
residual
provenance
The gap between differenced mispricing_s and the sum of the nine columns: 1.9e-16 at worst over 39,000 rows. Anything larger means the join is wrong. Sorting tick without day takes that same run to 0.149.
RNG substream
provenance
One of seven generators derived from the root seed: market, economy, external, jumps, volume, news and per-name volume. A new mechanism on its own stream perturbs nothing, however it draws.
RunManifest
provenance
The five things that identify a run, as one object: roster, macro initial conditions, realised scenario path, order log and strategy. reproduce() raises with the disagreeing component named.
sector factor
price formation
One normal per sector per tick, reaching each member through its sector loading. It blends toward the market factor above VIX 25.5, so diversification stops working exactly when it is most wanted.
seed
the run
One integer, separate from the universe seed. It does not identify a run on its own, because the market an agent trades depends on that agent's own orders.
sweep
the run
Streams one seed at a time. A hundred recorded 252-day 100-instrument engines alive at once is roughly 110 GB, against a little over 1 GB for one.
the nine factors
price formation
reversion, momentum, crowd_lean, company_news, order_flow_impact, short_squeeze_effect, random_noise, circuit_breaker and jump. Difference mispricing_s, add all nine, and you can check the label instead of trusting it.
tick
the run
One minute of game time. A day is 390 regular-session ticks, so a hand loop that passes the same hour and minute 390 times simulates a different market.
truth table
provenance
One row per instrument per tick carrying fundamental_value, anchor_price, mispricing_s and nine factor columns. The nine sum to the change in mispricing_s.
Universe
the run
The roster of instruments. Its order is contractual: the engine walks it in index order drawing random numbers as it goes, so a re-sorted universe gives a different market from the same seed.