From ce6035ee3cbf371b3c350a2c6b8413df10eb7985 Mon Sep 17 00:00:00 2001 From: Dennis Thiessen Date: Sat, 4 Jul 2026 10:01:59 +0200 Subject: [PATCH] Fix stale copy, dedupe Exit columns, document local report review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Follow-ups from review of the Track Record slim: - BacktestPanel: drop the stale "tracking check" sentence from the "How this is measured" explainer — that check moved to the maintenance disclosure last commit, so it no longer describes anything in this block. - MyTradesPanel: rename the two identically-labelled "Exit" columns to "Exit Px" (exit price) and "Reason" (close_reason) so they're not confusable. - README: add "Reading a local backtest report" under Local Backtest Snapshots — a section->decision map for reports/backtest-*.json. The strategy-tuning tables removed from the deployed page (sweep, gate_ablation, time_exit_sweep, signal_eval, strategy_variants) now live only in the local report, so this keeps "research lives local" from meaning the decision knowledge evaporates. tsc -b && vite build pass. Co-Authored-By: Claude Opus 4.8 --- README.md | 22 +++++++++++++++++++ .../src/components/signals/BacktestPanel.tsx | 3 +-- .../src/components/signals/MyTradesPanel.tsx | 4 ++-- 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3bce2c0..694c7fa 100644 --- a/README.md +++ b/README.md @@ -307,6 +307,28 @@ metrics. Keep the SSH tunnel open only while creating the snapshot; the backtest run itself is local/offline. `backtest_snapshots/` and generated backtest reports are git-ignored. +### Reading a local backtest report + +The deployed **Signals → Track Record** page is deliberately trimmed to validation +(portfolio monitor vs SPY, realized paper trades) and how-to-trade. The +strategy-tuning tables that used to live there now live **only** in the local +report — inspect these `reports/backtest-.json` sections and produce the +matching decision. Every change still goes through the factor harness first (see +**The iron rule for strategy changes** above). + +| Report section | What to read | Decision it drives | +|---|---|---| +| `overall_qualified` vs `overall_all` | Is qualified net expectancy above the all-setups baseline? | Sanity — is the gate adding anything at all | +| `sweep` | Net avg R and trade count at each residual-momentum cutoff | Where to set the momentum percentile (Admin → Settings → Activation) | +| `gate_ablation` | Net expectancy with each floor removed | Drop a floor only if removing it doesn't hurt net expectancy | +| `time_exit_sweep` | Net avg R / net R-per-day by hold length | Whether a fixed time exit beats the promoted ATR trail | +| `portfolio_monitor`, `portfolio_sim`, `strategy_variants` | CAGR, Sharpe, max drawdown, per-year returns | Promote a strategy only if it beats the current baseline on CAGR/Sharpe/DD | +| `signal_eval` | Mean IC, t-stat, IC>0 %, `reliable` | Iron rule: wire a new factor in only if \|IC\| ≳ 0.03 with a consistent sign and `reliable: true` | +| `recommendation`, `research_recommendation` | The report's own headline read | A starting point, not a substitute for the sections above | + +`recommendation` is the one section surfaced on the deployed page ("What this +backtest recommends"); everything else in this table is intentionally local-only. + ## Environment Variables Configure in `.env` (copy from `.env.example`): diff --git a/frontend/src/components/signals/BacktestPanel.tsx b/frontend/src/components/signals/BacktestPanel.tsx index 9371ec8..543d41a 100644 --- a/frontend/src/components/signals/BacktestPanel.tsx +++ b/frontend/src/components/signals/BacktestPanel.tsx @@ -180,8 +180,7 @@ export function BacktestPanel() { rebuilt using only data up to that day (no lookahead) and the following ~30 trading days decide its outcome — then simulates one capital-constrained book against the S&P 500. Sentiment and fundamentals are held neutral (no point-in-time history). ~6 months is roughly one market regime, - so read it as directional. The tracking check compares the backtest's qualified - expectancy with what live qualified setups have actually realized once matured. + so read it as directional.