From 1c0058ec3b80ed70aea61676694166dea2c0743f Mon Sep 17 00:00:00 2001 From: Adriano Dal Pastro Date: Sat, 16 May 2026 13:21:37 +0000 Subject: [PATCH] feat(strategy): swap BTC paper strategy a 9cf506b8 (hardened-001 robust winner) Sostituisce btc_fb63e851 (in produzione dal 13 maggio, net +$9.9k su 7y BTC, Sharpe medio -0.20) con btc_9cf506b8, vincitore del run phase1-hardened-001 (K=50 G=15 7y, fitness-v2 con hard-kill su fees_eat_alpha + negative_net_pnl). Performance comparate su 7y BTC continui: - btc_fb63e851: Net +$9,951 Sharpe medio -0.20 4/8 anni positivi - btc_9cf506b8: Net +$30,538 Sharpe medio +0.31 5/8 anni positivi Best year 2021: +$18,938 (vs prod +$6,835) Best Sharpe annuale: 2023 +1.27 (vs prod 2024 +1.16) Zero adversarial findings su 7y continui. Performance cross-asset (test su ETH 6.8y): - btc_fb63e851 su ETH: -$120 (pseudo-flat, nessun segnale) - btc_9cf506b8 su ETH: +$2,059 (4/7 anni positivi) La strategia generalizza out-of-asset, indicatore di robustezza non-ETH-overfit. DSL: physicist style, lookback 150 bar (~6 giorni). Triple-AND condition su realized_vol + atr_pct + sma_pct per entry (long o short). Exit su sma_pct=0 o vol collasso (<0.1%). Selettivo: 502 trade in 7y = 1.4 trade/giorno medio. btc_fb63e851 archiviato in strategies/archive/ per consultazione futura. Il glob loader `btc_*.json` e' non-ricorsivo, quindi archive/ non viene caricato automaticamente. Co-Authored-By: Claude Opus 4.7 (1M context) --- .../strategies/archive/btc_fb63e851.json | 142 ++++++++++++++++++ .../strategies/btc_9cf506b8.json | 140 +++++++++++++++++ 2 files changed, 282 insertions(+) create mode 100644 src/strategy_crypto/strategy_crypto/strategies/archive/btc_fb63e851.json create mode 100644 src/strategy_crypto/strategy_crypto/strategies/btc_9cf506b8.json diff --git a/src/strategy_crypto/strategy_crypto/strategies/archive/btc_fb63e851.json b/src/strategy_crypto/strategy_crypto/strategies/archive/btc_fb63e851.json new file mode 100644 index 0000000..3f79cb7 --- /dev/null +++ b/src/strategy_crypto/strategy_crypto/strategies/archive/btc_fb63e851.json @@ -0,0 +1,142 @@ +{ + "rules": [ + { + "condition": { + "op": "and", + "args": [ + { + "op": "gt", + "args": [ + { + "kind": "indicator", + "name": "rsi", + "params": [ + 14 + ] + }, + { + "kind": "literal", + "value": 70.0 + } + ] + }, + { + "op": "gt", + "args": [ + { + "kind": "indicator", + "name": "atr", + "params": [ + 14 + ] + }, + { + "kind": "indicator", + "name": "sma", + "params": [ + 14 + ] + } + ] + }, + { + "op": "gt", + "args": [ + { + "kind": "feature", + "name": "hour" + }, + { + "kind": "literal", + "value": 9 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "feature", + "name": "hour" + }, + { + "kind": "literal", + "value": 17 + } + ] + } + ] + }, + "action": "entry-short" + }, + { + "condition": { + "op": "and", + "args": [ + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "rsi", + "params": [ + 14 + ] + }, + { + "kind": "literal", + "value": 30.0 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "atr", + "params": [ + 14 + ] + }, + { + "kind": "indicator", + "name": "sma", + "params": [ + 14 + ] + } + ] + }, + { + "op": "gt", + "args": [ + { + "kind": "feature", + "name": "hour" + }, + { + "kind": "literal", + "value": 9 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "feature", + "name": "hour" + }, + { + "kind": "literal", + "value": 17 + } + ] + } + ] + }, + "action": "entry-long" + } + ] +} \ No newline at end of file diff --git a/src/strategy_crypto/strategy_crypto/strategies/btc_9cf506b8.json b/src/strategy_crypto/strategy_crypto/strategies/btc_9cf506b8.json new file mode 100644 index 0000000..a1aea64 --- /dev/null +++ b/src/strategy_crypto/strategy_crypto/strategies/btc_9cf506b8.json @@ -0,0 +1,140 @@ +{ + "rules": [ + { + "condition": { + "op": "and", + "args": [ + { + "op": "gt", + "args": [ + { + "kind": "indicator", + "name": "realized_vol", + "params": [150] + }, + { + "kind": "literal", + "value": 0.01 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "atr_pct", + "params": [150] + }, + { + "kind": "literal", + "value": 0.02 + } + ] + }, + { + "op": "gt", + "args": [ + { + "kind": "indicator", + "name": "sma_pct", + "params": [150] + }, + { + "kind": "literal", + "value": 0.05 + } + ] + } + ] + }, + "action": "entry-long" + }, + { + "condition": { + "op": "and", + "args": [ + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "realized_vol", + "params": [150] + }, + { + "kind": "literal", + "value": 0.005 + } + ] + }, + { + "op": "gt", + "args": [ + { + "kind": "indicator", + "name": "atr_pct", + "params": [150] + }, + { + "kind": "literal", + "value": 0.03 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "sma_pct", + "params": [150] + }, + { + "kind": "literal", + "value": -0.05 + } + ] + } + ] + }, + "action": "entry-short" + }, + { + "condition": { + "op": "or", + "args": [ + { + "op": "eq", + "args": [ + { + "kind": "indicator", + "name": "sma_pct", + "params": [150] + }, + { + "kind": "literal", + "value": 0.0 + } + ] + }, + { + "op": "lt", + "args": [ + { + "kind": "indicator", + "name": "realized_vol", + "params": [150] + }, + { + "kind": "literal", + "value": 0.001 + } + ] + } + ] + }, + "action": "exit" + } + ] +}