BtcOiSpikeDirectionalReversalLS
Hypotheses
BTC Open Interest Spike After Directional Move Reversal Long/Short (Daily, BINANCE USD-M, Crowded-Positioning Pre-Liquidation Signal)
Hypotheses
A long/short, single-instrument, single-venue, daily-cadence strategy on BTCUSDT.BINANCE that uses the factory's reliably-populated OPEN INTEREST supplementary data to detect crowded-leverage positioning and trade the subsequent mean-reversion. EXPLICITLY DESIGNED TO COMPLY WITH THE ANALYST'S 'venue_pivot_voids_hypothesis_roi' META-CONSTRAINT: uses ONLY KNOWN-RELIABLE data paths — BTCUSDT.BINANCE 1D bars (most stable bar source in the factory) + the OPEN_INTEREST supplementary feed (per factory.yaml supplementary_data list, populated by OpenInterestCollector and stored in PostgreSQL). NO venue-pivot risk because the target venue IS Binance USD-M from inception. Mechanism: when 7-day OI z-score (vs trailing 30-day mean/std) exceeds +2 sigma AFTER a directional price move, leveraged latecomers have piled into the move and the position is structurally fragile — the next ~3-day price move tends to mean-revert the recent direction. Specifically: large OI build during a rally = crowded longs (SHORT signal); large OI build during a selloff = crowded shorts (LONG signal — squeeze pending). Complementary to my prior BtcLiquidationCascadeReversal which fires on REALIZED forced flow; THIS strategy fires on PRE-flow positioning that often PRECEDES the liquidation. Together they form a 'leverage-cycle' book: OI-spike-divergence catches crowded positioning building; liquidation-cascade catches the unwind. Different mechanism class entirely, different primary supp data, different signal timing — no overlap. ABSENT FROM ALL 677 EXPERIMENTS: per my review, no strategy in the portfolio uses open_interest as primary signal. UNTOUCHED MECHANISM CLASS. ADDRESSES QUOTA GAPS: long_short direction (11.8% → ≥45% target; gap of ~33%, second-largest active gap); simple BTC daily bars (small Optuna search space, addresses 7-for-7 ADA 4H WF collapse meta-issue). FIVE PARAMETERS ONLY: oi_z_threshold, prev_return_threshold, profit_target_pct, stop_atr_mult, max_hold_days — radically simpler than failed strategies.
Hypotheses
Iteration 2 fixes the Layer-2 (synthetic) failure 'BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given'. Root cause: _to_ns was a @staticmethod, but the Layer-2 verification proxy rebinds strategy helpers as instance methods and passes self, so the 1-arg staticmethod received 2 args. The minimal fix converts _to_ns from a staticmethod to an instance method (drop @staticmethod, add self); its call site in _build_oi already invokes it as self._to_ns(...), so no other change is needed. Every other line -- OI series construction, causal OI sampling, 7-day build z-score, 7-day return, ATR%, entry/exit gates, and ATR-risk sizing -- is byte-identical to the previous iteration, preserving all Layer-1 checks (clean imports, subclass, methods) that already passed. This is the same recurring proxy gotcha where @staticmethod helpers invoked as self._helper(...) break only under the synthetic harness.
Hypotheses
BTC OI-spike directional-reversal fired exactly 1 trade in 4,712 bars (6+ years), with the lone entry dated 2026-04-12 and the engine flagging metrics_reliable=false — it is untestable. Root cause is a data-coverage failure, not the strategy: the signal requires oi_valid (>=8 daily OI deltas, i.e. ~15+ consecutive daily open_interest samples) before it can evaluate the z-threshold, and only ONE valid signal occurred across the entire history, meaning the open_interest supplementary feed has almost no historical coverage and _oi_at() returns None for nearly every bar. This is the SAME open-interest data gap that already sank the BtcOiSurge strategy this session and that the analyst has flagged as a data-engineering blocker; the hypothesis's premise that OI is 'reliably-populated' per factory.yaml is contradicted by the 1-trade result. The headline metrics are meaningless on n=1 (Sharpe 6.52 with sharpe_ci_low -6.84 / ci_high +32.5, win_rate 1.0 from a single short, profit_factor 0). Not optimize: a 3-phase optimization (walk-forward 3 windows + 15-day holdout) is impossible on 1 trade. Not iterate: the implementation is correct (causal lookup, multiple OI key-format fallbacks, sane sizing) and the blocker is structural historical OI coverage, which no parameter change or code fix can manufacture — it is a data-engineering backfill task. FAILURE PATTERN: open-interest-primary signals are currently unbacktestable on this engine because the open_interest supplementary feed lacks multi-year historical coverage (only recent data populated), so any OI-gated entry fires a handful of times or once across the full backtest — the same data-gap signature as the abandoned BtcOiSurge. The OI mechanism class should be shelved until the OpenInterestCollector backfills historical OI; the analyst's 'reliable-data-path' guidance should explicitly exclude open_interest for historical strategies until then.
Implementation
Long/short daily open-interest-spike-after-directional-move reversal on BTCUSDT.BINANCE USD-M futures. It samples the open_interest supplementary feed causally per daily bar, computes a 7-day OI build z-score versus a trailing ~30-sample baseline, and when the OI build exceeds oi_z_threshold after a directional 7-day price move it fades the move: crowded longs (big OI build during a rally) -> short, crowded shorts (big OI build during a selloff) -> long. It exits on the earliest of a profit target, an ATR-scaled stop, or max_hold_days. Five tunable parameters; OI/return windows and ATR period are fixed constants.
Verification Results
Verification failed (Layer 2 — synthetic scenarios):
Parameters used: ['min_notional', 'max_hold_days', 'stop_atr_mult', 'oi_z_threshold', 'profit_target_pct', 'prev_return_threshold']
Check that __init__ sets all attributes from self.parameters.get().
- steady_uptrend: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
- steady_downtrend: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
- flat_ranging: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
- volatility_spike: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
- zero_volume: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
- price_gap: TypeError: BtcOiSpikeDirectionalReversalLS._to_ns() takes 1 positional argument but 2 were given (bar timestamp: 1735690500000)
Backtest Review
Clean, correct implementation: causal OI lookup, multiple key-format fallbacks, sane ATR-risk sizing, simple 5-parameter design
Backtest Review
Genuinely novel signal class (OI-positioning) and a sound economic thesis (crowded-leverage pre-liquidation reversion)
Backtest Review
DECISIVE: only 1 trade in 4,712 bars (the single entry on 2026-04-12) — the open_interest supplementary feed has almost no historical coverage, so the signal never validates; metrics_reliable=false
Backtest Review
Headline metrics meaningless on n=1: Sharpe 6.52 with CI -6.84 to +32.5, win_rate 1.0, profit_factor 0; cannot support a walk-forward + holdout optimization
Backtest Review
Second OI-primary strategy this session blocked by the same OI data gap (BtcOiSurge already abandoned for it) — the 'reliably-populated' premise is contradicted by the result
Outcome Summary
BtcOiSpikeDirectionalReversalLS introduced a genuinely novel, economically sound mechanism — fading crowded-leverage positioning detected via open-interest build z-scores — deliberately routed to supposedly reliable Binance BTC daily bars plus the open_interest feed to avoid venue-pivot risk. The implementation was clean (causal OI lookup, key-format fallbacks, sane sizing), but the signal fired exactly one trade in six years because the open_interest feed has virtually no historical coverage, leaving metrics unreliable and untestable. This was the second OI-primary strategy of the session blocked by the identical data gap after BtcOiSurge. The analyst abandoned it on its second iteration as a data-engineering blocker no parameter change can fix, recommending the OI mechanism class be shelved until historical open interest is backfilled.
Outcome Summary
Open-interest-primary signals are currently unbacktestable because the open_interest feed lacks multi-year historical coverage — any OI-gated entry fires once or a handful of times across the full backtest — so the mechanism class should be shelved until the collector backfills history, and 'reliable-data-path' guidance should explicitly exclude open_interest for historical strategies for now.
Outcome Summary
The analyst abandoned it at the backtest-review gate before optimization because of a data-coverage failure rather than a strategy flaw: the open_interest supplementary feed has almost no historical coverage, so the OI lookup returned nothing for nearly every bar and only one valid signal ever occurred — the same OI data gap that had already sunk the BtcOiSurge strategy this session, contradicting the hypothesis's 'reliably-populated' premise.
Outcome Summary
A long/short, single-instrument BTCUSDT daily strategy using the open-interest supplementary feed to detect crowded leverage and fade the recent directional move — when the 7-day OI build z-score exceeded +2 after a directional price move, shorting crowded longs (OI build during a rally) or longing crowded shorts (OI build during a selloff), exiting on a profit target, ATR stop, or max-hold, with 5 parameters, as a pre-liquidation positioning complement to a liquidation-cascade strategy.
Outcome Summary
It was effectively untestable: the signal fired exactly 1 trade across 4,712 bars (a single short on 2026-04-12), with the engine flagging metrics_reliable=FALSE and the headline metrics meaningless on n=1 (Sharpe 6.52 with a CI of -6.84 to +32.5, win rate 1.0, profit factor 0, total return 0.25%).
Backtest and paper results are hypothetical. Trading involves risk of loss.