Quant Memo
Core

Experiment Tracking and Reproducibility

The practice of logging every detail of a research run — code version, data snapshot, parameters, and results — so that any past result can be exactly reproduced, compared fairly against other runs, and trusted months later when someone asks how a number was actually produced.

Prerequisites: In-Sample and Out-of-Sample Protocol

Six months ago you ran a model that scored a Sharpe ratio of 1.6 in backtest. A colleague asks to see it now, or you want to build on it — and you can't reproduce the number. Which data snapshot was it trained on? Which git commit? What was the random seed, the exact hyperparameters, the exact feature list? Without a system tracking these details automatically at the time of the run, a research result becomes an unverifiable rumor within weeks, even to the person who produced it. Experiment tracking is the discipline of recording everything needed to exactly reconstruct a result, every time a research script runs — not just the headline number, but every input that produced it.

An analogy: a chemist's lab notebook

A trained chemist doesn't just write down "the reaction produced 82% yield" — they log the exact reagent batch numbers, temperature, timing, and equipment used, because a result without that context can't be trusted, reproduced, or debugged if something looks off later. If a different batch produces 60% yield next time, the notebook is what lets them figure out whether it was the reagent batch, the temperature, or something else that changed. A quant research run deserves the same discipline: the "reagents" are the data snapshot and code version, the "conditions" are the hyperparameters and random seed, and the "yield" is the backtest Sharpe ratio or accuracy — none of which means anything in isolation from the others.

What gets logged, and why each piece matters

A complete experiment record captures: the exact code version (a git commit hash, not "the version from last Tuesday"), the exact data snapshot used (a versioned dataset identifier, since the "same" data source often gets restated or corrected over time), every hyperparameter and configuration value, the random seed (since many training procedures are stochastic and a different seed can produce a meaningfully different result from otherwise identical settings), and the resulting metrics and artifacts (the trained model file, evaluation plots, logs). In plain English: enough detail that someone with access to the same infrastructure, a year later, could re-run the exact experiment and get the exact same number back — and, just as importantly, could look at two different runs side by side and know exactly what changed between them.

Worked example: debugging a mysteriously better result

A researcher notices that a run logged last week scored a validation AUC of 0.71, while an apparently identical run today scores 0.68. Without tracking, this discrepancy is a mystery. With a full experiment log, the researcher pulls up both records side by side:

Last week's runToday's run
Code commita1b2c3da1b2c3d
Data snapshot2026-01-152026-07-20
Hyperparametersidenticalidentical
Random seed4242

Everything matches except the data snapshot — the underlying dataset was restated between the two runs (a common occurrence with fundamentals data that gets revised). The mystery is solved in minutes rather than days: the model didn't get worse and the code didn't break; the training data itself changed underneath the experiment, and the tracked snapshot identifiers made that immediately visible instead of triggering a fruitless hunt through the code.

code commit data snapshot hyperparameters random seed logged experiment record
Every input that could plausibly explain a result is recorded alongside it, so any two runs can be diffed and any past result can be reconstructed exactly.

What this means in practice

Experiment tracking pays off most visibly during a dispute or a debugging session, but its steady, quiet value is that it turns research from a pile of one-off scripts into an auditable record — critical when a research result eventually needs to justify real capital allocation, and equally critical simply for the researcher's own sanity when returning to work six months old. Tooling exists to automate most of this logging (so researchers don't have to remember to do it manually every time), but the discipline matters more than the specific tool: any workflow that lets a past result be silently unreproducible is a research liability waiting to surface at the worst time.

Experiment tracking logs the code version, data snapshot, hyperparameters, and random seed alongside every result, so any past experiment can be exactly reproduced and any two runs can be compared to find out precisely what changed between them.

"I re-ran the same script and got a different number" is almost never a mystery once you have proper tracking — it's nearly always an untracked difference in the data snapshot, an unpinned dependency version, or an unset random seed. Without tracking, that same discrepancy becomes an unsolvable, trust-eroding mystery.

Related concepts

Practice in interviews

Further reading

  • Sculley et al., Hidden Technical Debt in Machine Learning Systems
ShareTwitterLinkedIn