# Micro-trading strategy configuration
# All parameters here are thresholds and timing values.
# SIGIL_MODE in secrets-micro.env is the ONLY authoritative mode toggle.
# Do NOT add an enabled: true/false key here.

# Universe & watchlist
universe_refresh_seconds: 60
watchlist_max: 30

# Scoring
scoring_weights:
  volatility: 0.25
  momentum: 0.35
  liquidity: 0.25
  trend: 0.15
score_entry_threshold: 0.55       # watchlist promotion threshold
score_full_position: 0.70         # entry + full sizing threshold
signal_max_age_seconds: 30        # single TTL (SIMP-3)

# Momentum entry gates
min_consecutive_candles: 3
volume_surge_threshold: 3.0
spread_max_pct: 0.3
rsi_entry_min: 40.0               # RSI(14) exclusive lower bound
rsi_entry_max: 70.0               # RSI(14) exclusive upper bound (ERG-2)
depth_imbalance_ratio: 1.3        # single fresh check at entry gate
resistance_threshold_pct: 3.0

# Anti-spoof (runs at watchlist promotion, not entry gate — SIMP-2)
antispoof_samples: 3
antispoof_window_ms: 2000
antispoof_blacklist_minutes: 5

# RSI exit accelerator
rsi_exit_accelerator: 70.0        # RSI(14) >= 70 triggers ratchet (trailing)

# Exit parameters
take_profit_pct: 5.0
partial_tp_pct: 3.5
partial_tp_fraction: 0.6
stop_loss_pct: 3.0
stop_loss_limit_buffer_pct: 0.35
time_exit_minutes: 20
dead_man_max_hold_hours: 4

# Order execution
order_type: "limit_maker"
fill_window_seconds: 30
cooldown_after_unfilled_minutes: 30
cancel_max_retries: 3
cancel_backoff_seconds: 2
sl_attachment_max_retries: 3
sl_attachment_backoff_seconds: 2

# Position sizing (integration-notes section 3: architecture session values)
max_simultaneous: 10              # capped; actual = floor(portfolio / $15)
max_total_exposure_pct: 15.0      # supersedes signal session's 6%
base_position_pct: 5.0
half_position_pct: 2.5
min_notional_usd: 5.0
max_position_pct: 10.0
reentry_cooldown_hours: 2.0

# Capital isolation
capital_pct: 50.0                 # % of portfolio reserved for micro tier

# TTL worker
ttl_minutes: 25

# Score cache
score_cache_ttl_seconds: 90       # R-6: tighter than architecture's 300s
score_cache_maxsize: 50

# Circuit breaker
circuit_breaker_loss_pct: 8.0

# --- Big-Mover feature (WU5, 2026-04-21) ---

regime:
  fear_greed_pause: 25.0
  btc_price_change_halt_pct: 5.0
  btc_dom_advisory: 60.0
  eth_btc_slope_reduced: 0.0
  reduced_score_threshold: 0.75

watchlist_filter:
  min_mc: 8000000
  max_mc: 120000000
  vol_mc_ratio: 0.15
  circ_supply_ratio: 0.35
  mc_bypass_threshold: 20000000

gates:
  volmc_spot_ratio_threshold: 0.15
  volmc_prior_avg_max: 0.05
  squeeze_min_candles: 4
  squeeze_vol_pct: 0.40
  depth_slope_min: 0.01
  derivatives_futures_spot_ratio: 3.0
  derivatives_oi_pct_threshold: 15.0
  derivatives_funding_threshold: -0.0005
  derivatives_score_bonus: 0.15
  tvl_change_threshold: 30.0
  tvl_score_bonus: 0.10
  ath_risk_exit_multiplier: 0.75
