Monte-Neo¶
The independent verifier for trading strategies written by AI agents and humans
Catch look-ahead bias, hidden trading costs and overfitting before a backtest reaches your money
Install
pip install monte-neo
monte-neo verify --ohlcv prices.csv --strategy my_strategy.py --n-trials 12
The problem¶
A coding agent can turn a trading idea into a backtest in minutes, and then report a Sharpe of 3. Most of the time that number is wrong:
- Look-ahead bias: the code reads future bars (
shift(-1), centred windows,bfill, whole-series statistics,np.gradient, FFT filters). - Missing costs: the edge is smaller than fees and slippage, or needs a perfect fill.
- Selection bias: the best of 300 variants is reported as if it were the only one.
What Monte-Neo does¶
It checks the backtest, not the idea. Give it the price data and the strategy code or its
positions. It returns PASS, PASS_WITH_WARNINGS, NEEDS_MORE_EVIDENCE or REJECT, the
checks behind the verdict, concrete next steps for the agent, and a reproducible strategy-verdict/1
certificate that can be signed.
| Family | Checks |
|---|---|
| Look-ahead | Truncation and future-perturbation probes, outside-data watch, static AST lint (23 rules), implausible hit rate |
| Economics | Net return after costs, break-even cost in bps, one- and two-bar execution delay |
| Statistics | Probabilistic and Deflated Sharpe priced by n_trials, Monte Carlo timing test, sample size, holdout; walk-forward and parameter plateau for grids |
| Integrity | Broken OHLCV (NaN, bad prices, bars out of time order), non-deterministic signals |
New in v0.53: from a rejected backtest to a committee
- Repair without overfitting: defects fixed, choices made by the number of defects on 70 % of
the history, a lockbox opened once, and an honest
REPAIRED_NO_EDGEwhen the profit was the defect. - Alpha validation with an Alpha Readiness Level: signal power, factor attribution, capacity, robustness, value to your book.
- Validation dossier and live monitor: evidence mapped to SR 11-7, PRA SS1/23 and MiFID II RTS 6; alarms when the edge dies after launch.
- ML models and event data, track records from returns, policy, tracker trials and LLM cutoffs, a reference alpha.
New: catch look-ahead that hides in milliseconds¶

A quote has two times: when the exchange stamped it and when it reached you. A backtest that bins by the stamp lets a fast
strategy trade on prices it could not have seen yet, and no code lint can find that. monte-neo verify --quotes runs the
strategy on the time the data arrived, names the delay in ms where its profit vanishes, redraws the observed latency
200 times and issues a certificate you can reproduce. Read the guide.
Where to use it¶
- Inside your coding agent: Claude Code plugin, or the MCP server for Codex, Gemini CLI and Cursor. See Use from agents.
- In CI: a GitHub Action that fails the pull request on
REJECTand posts the verdict. - When reviewing someone else's strategy: re-check their certificate and verify its signature.
- When screening submissions at a prop firm, marketplace or course.
- When comparing agents: the Honesty Bench.
Learn more¶
- Verifier API: checks, verdicts, certificates, re-checks and signatures
- Frameworks and notebooks: vectorbt, Freqtrade, Lean, Zipline, Jupyter, pre-commit, badge, Docker
- Trap Suite: 80 strategies that lie and 35 honest controls, and how to add yours
- Honesty Bench: score how honestly agents report backtests
- Verify a certificate: check a signed certificate in your browser
- Six ways your agent's backtest lies: the traps, with numbers
- FAQ · Changelog · Roadmap
Research engine (maintenance mode)¶
Monte-Neo started as a fast local research engine for Apple Silicon: fee-aware next-bar backtests, parameter sweeps with golden vectors, Monte Carlo helpers and a paper OMS, with Metal / MLX / Numba device selection. The verifier runs on this engine. The engine still works and receives bug fixes, but new work goes into the verifier.
from monte_neo.backtest import ExecutionModel, export_sma_sweep, synthetic_ohlcv
ohlc = synthetic_ohlcv(100_000, seed=42)
model = ExecutionModel(commission_bps=5.0, slippage_bps=5.0, warmup_bars=50)
out = export_sma_sweep(ohlc["open"], ohlc["high"], ohlc["low"], ohlc["close"], combos=16, model=model, device="auto")
print(out["device"], out["combos"])
See the quick start and the export API.


Source: github.com/NeoZorK/Monte-Neo · MIT license · Not investment advice.