prod/configs/green.yml: - asset_bucket_ban_set: [4] (B4 banned at selector level) - s6_size_table: inline bootstrap multipliers (B0→0.4, B1→0.3, B3→2.0, B5→0.5, B6→1.5) matching CRITICAL_ASSET_PICKING S6 scenario - esof_sizing_table: FAV→1.2, MILD_POS→0.6, UNKNOWN→0.25, MILD_NEG→0.0, UNFAV→0.0 - use_int_leverage: true (1x fixed pending winrate analysis) - s6_table_path: pointer to generated YAML (recompute updates this) BLUE (blue.yml) carries none of these keys → BLUE math unchanged. prod/configs/green_s6_table.yml: bootstrap stub with frontmatter (generated_at, source_branch, n_trades). Regenerated by recompute script. prod/scripts/recompute_s6_coefficients.py: Queries trade_events, maps assets to KMeans buckets, derives per-bucket sizing mults. Variance guard: >20% net-PnL move flags bucket in dolphin.s6_recompute_log for manual review before promote. prod/s6_recompute_flow.py: Prefect flow wrapping the recompute script. Cadence via S6_RECOMPUTE_INTERVAL_DAYS env (default 30). Kill-switch: S6_RECOMPUTE_DISABLED=1. prod/scripts/analyze_leverage_winrate.py: Read-only walk of CH trade_events; bins trades by leverage_raw, emits per-bin WR/net-PnL/avg-MAE. Output informs the int-leverage rounding rule choice (Option 1 round-half-up vs Option 2 banker's round vs stay-at-1x). Does not auto-apply a rule change. Plan refs: Tasks 3, 8, 10. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
113 lines
5.1 KiB
YAML
Executable File
113 lines
5.1 KiB
YAML
Executable File
# GREEN — SHORT-only mirror of BLUE + V7 RT exit engine (experimental staging)
|
||
#
|
||
# BLUE compliance (2026-04-13):
|
||
# direction : short_only (was: long)
|
||
# boost_mode : d_liq (NEW — matches BLUE's create_d_liq_engine)
|
||
# max_hold_bars : 250 (matches BLUE live; OB cascade halves to ~125)
|
||
# min_irp_alignment : 0.0 (was: 0.45 — matches BLUE's ENGINE_KWARGS)
|
||
# max_leverage : 8.0 (D_LIQ soft cap; informational)
|
||
# abs_max_leverage: 9.0 (D_LIQ hard cap; informational)
|
||
# vol_p60 : 0.00009868 (gold canonical — matches BLUE)
|
||
# hazelcast.state_map: DOLPHIN_STATE_GREEN
|
||
#
|
||
# V7 additions (GREEN only):
|
||
# use_exit_v7 : true (V7 = vol-normalized MAE + bounce_score/risk ML)
|
||
# v6_bar_duration_sec : 5.0 (eigenscan cadence; swap to 1.0 when NT runs 1s bars)
|
||
# bounce_model_path : path to bounce_detector_v3.pkl
|
||
# Rollback: set use_exit_v7: false, use_exit_v6: true to revert to pure V6
|
||
|
||
strategy_name: green
|
||
direction: short_only
|
||
|
||
engine:
|
||
boost_mode: d_liq # BLUE compliance: D_LIQ engine (LiquidationGuardEngine)
|
||
vel_div_threshold: -0.02
|
||
vel_div_extreme: -0.05
|
||
min_leverage: 0.5
|
||
max_leverage: 8.0 # D_LIQ soft cap (informational — d_liq ignores this)
|
||
abs_max_leverage: 9.0 # D_LIQ hard cap (informational — d_liq ignores this)
|
||
leverage_convexity: 3.0
|
||
fraction: 0.20
|
||
fixed_tp_pct: 0.0095
|
||
stop_pct: 1.0
|
||
max_hold_bars: 250 # BLUE compliance; OB cascade halves to ~125 at runtime
|
||
use_direction_confirm: true
|
||
dc_lookback_bars: 7
|
||
dc_min_magnitude_bps: 0.75
|
||
dc_skip_contradicts: true
|
||
dc_leverage_boost: 1.0
|
||
dc_leverage_reduce: 0.5
|
||
use_asset_selection: true
|
||
min_irp_alignment: 0.0 # BLUE compliance (was 0.45)
|
||
use_sp_fees: true
|
||
use_sp_slippage: true
|
||
sp_maker_entry_rate: 0.62
|
||
sp_maker_exit_rate: 0.50
|
||
use_ob_edge: true
|
||
ob_edge_bps: 5.0
|
||
ob_confirm_rate: 0.40
|
||
lookback: 100
|
||
use_alpha_layers: true
|
||
use_dynamic_leverage: true
|
||
seed: 42
|
||
# V7 RT exit engine (GREEN only — observer mode; not present in BLUE config)
|
||
use_exit_v7: true # V7: vol-normalized MAE + bounce_score/risk ML injection
|
||
use_exit_v6: false # V6 fallback — set true here + false above to roll back
|
||
v6_bar_duration_sec: 5.0 # scan cadence; set 1.0 when NT runs 1-second bars
|
||
bounce_model_path: /mnt/dolphinng5_predict/prod/models/bounce_detector_v3.pkl
|
||
|
||
paper_trade:
|
||
initial_capital: 25000.0
|
||
data_source: live_arrow_scans
|
||
log_dir: paper_logs/green
|
||
vol_p60: 0.00009868 # gold canonical (was 0.000099)
|
||
|
||
hazelcast:
|
||
imap_pnl: DOLPHIN_PNL_GREEN
|
||
imap_state: DOLPHIN_STATE_GREEN
|
||
state_map: DOLPHIN_STATE_GREEN # capital persistence map (was defaulting to BLUE)
|
||
|
||
# ──────────────────────────────────────────────────────────────────────────────
|
||
# GREEN S6/EsoF/AEM sprint (exp/green-s6-esof-aem-shadow-2026-04-21).
|
||
# BLUE (prod/configs/blue.yml) does NOT set these keys → orchestrator loads them
|
||
# as None/False → BLUE math is byte-identical pre-sprint. To disable any branch
|
||
# on GREEN, comment the corresponding key — single kill-switch per feature.
|
||
# ──────────────────────────────────────────────────────────────────────────────
|
||
|
||
# Strictly-zero buckets banned at the ranking layer (selector skips them so the
|
||
# slot is handed to the next-best asset — does NOT waste capital with 0× sizing).
|
||
# Fractional buckets (B0/B1/B5) stay tradeable via s6_size_table below.
|
||
asset_bucket_ban_set: [4]
|
||
|
||
# Pointer to the generated S6 coefficient table. prod/scripts/recompute_s6_coefficients.py
|
||
# regenerates this file on the configured cadence (env S6_RECOMPUTE_INTERVAL_DAYS).
|
||
# Bucket → per-entry notional multiplier applied at esf_alpha_orchestrator.py single-site.
|
||
s6_table_path: prod/configs/green_s6_table.yml
|
||
|
||
# Inline fallback used when s6_table_path is missing (bootstrap / first-run):
|
||
# matches the S6 row from prod/docs/CRITICAL_ASSET_PICKING_BRACKETS_VS._ROI_WR_AT_TRADES.md.
|
||
# B4 is absent (banned above); B2 is absent (= 1.0x, no-op).
|
||
s6_size_table:
|
||
0: 0.40
|
||
1: 0.30
|
||
3: 2.00
|
||
5: 0.50
|
||
6: 1.50
|
||
|
||
# EsoF regime gate lives at the top of _try_entry (orchestrator single-site).
|
||
# mult == 0 → regime-wide skip (no selector/sizer work). UNKNOWN replaces NEUTRAL
|
||
# (signals-in-conflict is empirically the worst ROI state).
|
||
esof_sizing_table:
|
||
FAVORABLE: 1.20
|
||
MILD_POSITIVE: 0.60
|
||
UNKNOWN: 0.25
|
||
NEUTRAL: 0.25 # alias — historical CH rows / stale HZ snapshots
|
||
MILD_NEGATIVE: 0.00
|
||
UNFAVORABLE: 0.00
|
||
|
||
# Target exchanges (e.g. Binance) require integer leverage. Default 1x pending
|
||
# CH-trade-walk in prod/scripts/analyze_leverage_winrate.py to pick the rounding
|
||
# rule (round-half-up vs banker's round vs stay-at-1x). leverage_raw is preserved
|
||
# in CH trade_events + NDPosition for that analysis.
|
||
use_int_leverage: true
|