Research & Validation

Building toward an all-weather system — profitable in bull OR bear — the validate-first way. Tools, backtests, and cross-regime findings live here.

North star: regime-robustness comes from neutrality + decorrelation + validate-first, not from a better directional bet. This is a long-term research effort — paper money is tuition.

The principles we're building toward

What actually makes a system make money in any regime.

Validate-first
An edge must prove itself out-of-sample, ACROSS regimes, before it risks capital. No more deploy-live-and-learn-by-losing.
Decorrelation
Many uncorrelated edges, so any one failing washes out. One momentum bet in twenty costumes is not diversification.
Neutrality
Reduce directional / market-beta exposure (toward balanced long-short) so the market's direction matters less.
Portfolio risk
Size by portfolio risk, correlation, and volatility — not per-trade.

Latest finding — first all-weather map

5-year backtest across bull / neutral / bear (incl. the 2022 bear). A backtest, not live fills — validate further before trusting.

2026-06-08
All-weather corepocket_pivot (+0.22R, n=1108, positive in bull, neutral AND bear) · sma200_reclaim · volume_climax_bottom
Bear hedgegap_fill_reversal — loses slightly in bull (−0.04R) but makes +1.35R in bear: a mean-reversion edge that profits when momentum dies.
Bull-only / fragilemacd, rsi_oversold_bounce, vcp_breakout — positive in bull, negative in bear (what we'd been leaning on).

All-weather forward validation (shadow run)

Observe-only — pocket_pivot + gap_fill on the real tradeable universe, no capital. The survivorship-free forward test the backtest can't do.

live
Why this exists:the 15-year backtest of this pair passed out-of-sample, temporal (5 bears) and transaction-cost gates — but a survivorship check showed the headline was inflated: on a non-winner universe it's roughly breakeven net of costs. The durable piece is gap_fill as a bear-hedge. This forward record has no survivorship bias by construction— it's the honest test, and it decides whether the pair is real.

Intraday give-back — shadow profit-protection

Observe-only. What a profit-lock (flatten after the day's P&L pulls back from its peak) WOULD do vs holding to the 15:55 flatten, replayed over recorded intraday curves.

tuning
Arm above
Pullback

Multi-regime backtest

5-year daily backtest of every swing scanner, edge by market regime. A first-touch backtest on a 20-name universe — not live fills.

Running the 5-year backtest (~a minute the first time; cached for a day after)…

Backtest & harness tools

Read-only research scripts in backend/scripts/ — run against the live DB / Alpaca. Dashboards for these land here as they're built.

scripts/edge_harness.py
Per-scanner edge by regime (from resolved recs) + inter-scanner correlation (from live trades). V1 finding: live history is 100% bull — all-weather isn't measurable from live data alone.
scripts/regime_backtest.py
5-year daily backtest of every swing scanner, edge stratified by bull / neutral / bear + monthly-return correlation. Produced the all-weather map above.
See RESEARCH.md at the repo root for the full tooling index, roadmap, and dated findings log.