Local-first · Open source · MIT

QuantVault

A local quant-research operating system for the full experimentation lifecycle. Record every backtest, sweep, and paper trade - then compare, analyze, validate, reproduce, and explore from Python or the terminal. Your data stays on your machine.

quant-vault · local session
$ quant-vault init
Initialized ledger at ./.quantvault/ledger.db

$ quant-vault record mean_reversion --param lookback=20 --tag pilot
{ "id": "a1b2c3d4e5f6", "status": "created", ... }

$ quant-vault analyze a1b2 --file run.json
$ quant-vault validate a1b2
$ quant-vault montecarlo a1b2 --file run.json --sims 500
$ quant-vault dashboard
QuantVault dashboard at http://127.0.0.1:8787/

Install

Python 3.10+. No cloud account. Optional Parquet support via an extra.

install
pip install QuantVault

# from source
pip install -e ".[dev]"

# optional parquet export
pip install "QuantVault[export]"
CLI: quant-vault alias: quantvault storage: ./.quantvault/ PyPI: QuantVault 0.1.1

How to use

QuantVault does not replace your backtest engine. You run research as usual - then register results in the ledger.

  1. Init a ledger in your research folder.
    quant-vault init creates ./.quantvault/ledger.db.
  2. Record an experiment when you launch (or finish) a run - strategy, params, tags, parent id.
  3. Analyze with equity / returns / trades JSON. Metrics and chart artifacts are stored locally.
  4. Validate research quality: quant-vault validate <id>.
  5. Optional Monte Carlo for distribution / fan charts: quant-vault montecarlo <id> --file run.json.
  6. Compare, lineage, export, dashboard whenever you need answers - all offline.
Tip: experiment ids accept unambiguous prefixes - quant-vault show a1b2 works if only one id starts with a1b2.

Python API

Same core as the CLI. Open a ledger, record runs, attach analysis and reproducibility metadata.

python
from quantvault import Ledger

with Ledger.open() as ledger:
    exp = ledger.record(
        "mean_reversion",
        parameters={"lookback": 20, "threshold": 1.5},
        tags=["pilot"],
    )

    # ... run your backtest ...

    ledger.analyze(
        exp.id,
        equity=equity_curve,
        trades=[{"pnl": 12.5, "notional": 10_000}],
        benchmark_returns=bench,
        cost_bps=5,
        slippage_bps=2,
    )
    ledger.validate(exp.id)
    ledger.run_monte_carlo(exp.id, returns, n_sims=500, seed=7)
    ledger.attach_repro(exp.id, seed=7, packages=["numpy"])

    print(ledger.compare(exp.id, other_id))
    print(ledger.list(strategy="mean_reversion", tag="pilot"))

Full CLI reference

Professional command surface. Global flag: --root PATH to choose the ledger directory.

Experiment management

CommandWhat it does
quant-vault initCreate local ledger
quant-vault record STRATEGY [--param k=v] [--tag T] [--parent ID]Record a research run
quant-vault create NAME [--strategy S] [--param k=v] [--tag T] [--parent ID]Register a named experiment
quant-vault list [--strategy S] [--status S] [--tag T] [-q QUERY] [--json]Search / filter
quant-vault show IDPrint one experiment
quant-vault set ID [--name N] [--strategy S] [--status S] [--param k=v]Update fields
quant-vault tag ID TAG [TAG...]Add tags
quant-vault note ID TEXTAppend annotation
quant-vault compare LEFT RIGHTDiff params / metrics / tags
quant-vault lineage ID [--json]Ancestors + children
quant-vault journal [TEXT] [--experiment ID]Research journal
quant-vault checkpoint [NAME ID...] [--note TEXT]Freeze a set of runs
quant-vault profile [NAME] [--set] [--param k=v]Strategy profiles

Analysis and validation

CommandWhat it does
quant-vault analyze ID [--file run.json] [--cost-bps N] [--slippage-bps N]Performance report
quant-vault validate IDQuality / integrity / bias / repro checks
quant-vault risk IDRisk snapshot
quant-vault srsi ID [--file run.json] [--window N]Sharpe Ratio Stability Index
quant-vault montecarlo ID --file run.json [--sims N] [--seed N]Monte Carlo fan + distribution
quant-vault robustness ID [ID...] [--metric sharpe]Neighborhood stability
quant-vault walkforward ID [--file windows.json]Walk-forward analysis
quant-vault overfit ID [--in-sample N] [--out-of-sample N] [--trials N]IS/OOS overfitting gap
quant-vault sensitivity NAME --grid JSONSensitivity batch
quant-vault sweep [NAME] [--strategy S] [--grid '{...}'] [--parent ID]Parameter sweep -> child experiments
quant-vault batch [--name N] [--file specs.json]Create / list batches
quant-vault chart ID --file chart.json [--name NAME]Store custom chart
quant-vault adapt FRAMEWORK --file result.json [--dry-run]Import via framework adapter

Data and reproducibility

CommandWhat it does
quant-vault dataset --register NAME --path FILE [--version V]Fingerprint and register dataset
quant-vault dataset [--name N] [--lineage ID]List / lineage
quant-vault artifact EXP [--file PATH] [--name NAME]Store / list artifacts
quant-vault repro --attach ID [--config cfg.json] [--dataset ID] [--seed N]Attach repro record
quant-vault repro --show IDShow repro record
quant-vault reproduce IDBundle needed to re-run

Portfolio, live, export, dashboard

CommandWhat it does
quant-vault portfolio --name N --file legs.jsonMulti-strategy portfolio
quant-vault live --name N --backtest ID [--kind paper|live]Paper/live vs backtest
quant-vault report [ID] [--format json|html|csv|parquet] [--out PATH]Research report
quant-vault export [ID] [--format json|csv|html|parquet] [--out DIR]Export experiment(s)
quant-vault import FILE.jsonImport experiment pack
quant-vault backup [--out backup.zip]Zip DB + artifacts
quant-vault restore ARCHIVE.zipRestore into ledger root
quant-vault config [--set k=v]Local configuration
quant-vault pluginsPlugins / custom metrics / adapters
quant-vault dashboard [--host 127.0.0.1] [--port 8787]Local visualization UI

Analyze / Monte Carlo input file

run.json
{
  "equity": [100, 101.2, 100.8, 102.5],
  "returns": [0.012, -0.004, 0.017],
  "trades": [{"pnl": 15.0, "notional": 10000}],
  "benchmark_returns": [0.001, 0.0, 0.002]
}

Everything QuantVault can do

Built as a thin local layer around your existing research workflow.

Experiment management

Registry, search, tags, notes, compare / what-changed, lineage, checkpoints, journal, strategy profiles.

Performance analysis

Equity, drawdown, Sharpe/Sortino/Calmar, trades, costs and slippage, benchmark, SRSI, Monte Carlo, walk-forward, sweeps, robustness.

Data and reproducibility

Dataset fingerprinting, versions, data lineage, config snapshots, env/package tracking, seeds, artifact storage.

Research quality

Warnings, integrity, data quality, lookahead / survivorship / leakage heuristics, reproducibility validation.

Portfolio research

Multi-strategy portfolios, allocation, correlation, portfolio risk and drawdown.

Paper / live

Track paper and live fills locally and compare against the original backtest.

Visualization

Local Bloomberg-style dashboard and HTML reports. Charts only - no strategy verdicts.

Export / backup

JSON, CSV, HTML, Parquet (optional), import packs, full DB+artifact zip backup/restore.

Integrations

Custom metrics, custom metadata, plugin hooks, and built-in adapters for generic / vectorbt / backtesting.py / zipline-style payloads.

Privacy by default

Nothing is uploaded. Ledgers, exports, and secrets are gitignored. Repro metadata avoids home-directory paths.

Local dashboard

Read-only visualization on the same ledger. Monitor blotter, strategy books, portfolios, paper/live runs, and full experiment pages with equity, drawdown, Monte Carlo, validation, walk-forward, trades, costs, and repro panels.

dashboard
quant-vault dashboard
# http://127.0.0.1:8787/
# /experiment/<id>
# /strategy/<name>

# synthetic end-to-end demo
python examples/demo_everything.py

Design principle

The dashboard is not the product core. Python API + CLI own the workflow. The UI only renders what you already stored - metrics and charts for you to interpret.

localhost only same SQLite ledger no cloud sync

Architecture

One local core. Three interfaces. Every substantive feature is available from Python and the CLI.

architecture
                 QUANTVAULT
                      |
                +-----+-----+
                | Local Core |  experiments · analytics · validation
                |            |  reproducibility · storage · research
                +-----+-----+
          +-----------+-----------+
          |           |           |
     Python API      CLI    Local Dashboard
          +-----------+-----------+
                      |
               Local Storage
            SQLite · files · artifacts

Privacy

This documentation site and the public GitHub repo contain the package only - never your strategies, fills, or market data.

.quantvault/ ignored exports / backups ignored .env and keys ignored no absolute home paths in repro