Files
fxhnt/tests/unit
jgrusewski 07e0daa669 feat(cockpit): Bybit 4-edge book — configurable backtest (precomputed sleeve returns) + live forward track, clearly labeled
Present the Bybit 4-edge book in the cockpit as BOTH a configurable backtest
AND the live forward track, clearly distinguished.

- bybit_sleeve_ret table + PaperRepo upsert/read: the PRECOMPUTED per-sleeve
  daily returns the sim reads (never recomputes the heavy 4-edge book on a web
  request). Mirrors paper_sleeve_ret's shape.
- bybit_4edge_nav asset also persists the 4 sleeves' full daily return series
  via persist_bybit_sleeve_returns (same live runners, memory-bounded, guarded
  so it never fails the forward track). Idempotent.
- /paper/sim book selector: binance_combined (overlay, existing default) and
  bybit_4edge (NAIVE equal-weight, NOT the overlay — A/B proved naive best OOS)
  via simulate_naive_eqwt; capital/start/cost_bps are the cheap in-memory knobs.
- Bybit view shows the configurable BACKTEST curve AND the live FORWARD track
  (forward_nav) labelled distinctly, with the forward gate status / N-of-60 days.
- Tests: naive eq-wt sim unit tests; asset persistence + idempotency + no-clobber
  + matches bybit_book_eval baseline; book-selector web smoke incl. a tripwire
  proving the request path never calls the heavy edge compute; Binance sim
  unchanged. Full suite green (1147 passed).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-24 17:27:10 +02:00
..