The strategy evidence engine: honest PASS/WARN/BLOCK verdicts on trading strategies. Its credential: it blocked its own flagship strategy.
Project description
Disprove
The strategy evidence engine. Disprove decides whether a trading strategy has earned the right to risk money — and refuses when it hasn't.
pip install disprove
Its credential: it blocked its own flagship strategy
Disprove was extracted from a private trading-research system whose best strategy — delta-neutral funding-rate carry, 6.7 years of real Binance data, +11.8%/yr average — looked fundable by every conventional measure. The fixed-horizon audit returned BLOCK: only ~1 month in 3 was actually clean; the average was carried by two hot regimes. Thresholds were anchored to observables and committed in writing before the run. The verdict was accepted and the strategy was never funded.
A validation tool that has never rejected its owner's favorite idea is a rubber stamp. Read the full story: docs/case-study.md.
60-second demo (no keys, no data, no network)
python examples/run_synthetic_audit.py
consistent -> PASS (4P/0W/0B of 4, pass_ratio=1.00, reasons=clean)
inconsistent -> WARN (1P/3W/0B of 4, pass_ratio=0.25, reasons=['pass_ratio_below_threshold'])
gapped -> BLOCK (3P/0W/2B of 5, pass_ratio=0.60, reasons=['blocked_chunks_present'])
The third line is the point: a profitable-looking history with missing data is blocked on integrity — before performance is even considered.
What it does
- Fixed-horizon chunks. Your strategy's history is split into fixed calendar windows (default 30 days). Every window between first and last observation is emitted — missing history cannot disappear from the count.
- Integrity blocks. Partial windows, data gaps, and thin chunks BLOCK. Untrustworthy evidence is not neutral; it is disqualifying.
- Per-chunk verdicts. PASS needs positive fee-adjusted PnL and bounded drawdown inside each window — a pretty average cannot hide bad months.
- An overall verdict you committed to in advance. Anchor your thresholds
to observables (your max drawdown, your monthly expectancy), write them
down, then run.
evaluate_overall_verdictdoes the rest.
from disprove import (
CostModel, CarryAuditPolicy, FixedHorizonChunkPolicy,
audit_funding_carry_chunks,
)
audit = audit_funding_carry_chunks(
funding_frame, # polars: funding_time (ms), funding_rate
cost_model=CostModel(spot_fee_bps=10, perp_fee_bps=5, half_spread_bps=1, slippage_bps=2),
policy=CarryAuditPolicy(window=6, notional_usdt=10_000),
chunk_policy=FixedHorizonChunkPolicy(
catastrophic_net_loss_usdt=-150.0, # anchor: your full-history maxDD
max_pass_drawdown_usdt=40.0, # anchor: one month's expected profit
),
horizon_ms=30 * 24 * 3600 * 1000,
)
print(audit.overall.verdict) # PASS | WARN | BLOCK — with receipts
Also included: cost-charged vectorized carry backtests (run_backtest,
basis-aware run_backtest_v2), deflated Sharpe and walk-forward splits
(disprove.metrics, disprove.walkforward), and a CLI (disprove --help)
that writes auditable Markdown + CSV verdict artifacts.
What this is not
- Not a signal service. Not a profit bot. No profitability claims — the flagship case study documents a rejection; that is the product.
- Not a full backtesting framework: it is the judgment layer you put on top of whichever one you use.
Provenance
Extracted from a private research system with 1,000+ tests; this public core ships with its own test suite and CI. The private system also rejected, with receipts: orderbook scalping for non-colocated operators (fees + adverse selection) and cross-sectional funding rotation (turnover costs).
Paid: independent audits
The author runs this gate against client strategies under pre-committed thresholds — your rules, your data window, an honest verdict with receipts. Contact via GitHub issues or the email in the commit log.
MIT licensed.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file disprove-0.1.0.tar.gz.
File metadata
- Download URL: disprove-0.1.0.tar.gz
- Upload date:
- Size: 64.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
22ebf6e7d5ada70a1329f691fc2d5fbc89293b65983443aa28c387e1feefb5e8
|
|
| MD5 |
491321ed6f3c18e1cf6033bfbee1c95f
|
|
| BLAKE2b-256 |
eafcf0d4d72f95ea36363e8f3d4c5d8f4f0d30f2239d63e00d0ff2060c61d1ee
|
File details
Details for the file disprove-0.1.0-py3-none-any.whl.
File metadata
- Download URL: disprove-0.1.0-py3-none-any.whl
- Upload date:
- Size: 20.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
986e6c5c5a88aacfc0dfd4a6f6445855a0f8fabb32688bd8945938426ea15690
|
|
| MD5 |
2b0fb70e889b69c0de34c9b9f6892108
|
|
| BLAKE2b-256 |
7121fd6dabf198d04f5cb3877df01e56c9a9b875c59022c972fb4635e34ffd0a
|