Plan 3 Task 6c. Portfolio-state tail-append: - PS_PRE_ENTRY_CONVICTION_EMA = 41 (EMA mean of conviction_core during Flat) - PS_PRE_ENTRY_CONVICTION_VAR_EMA = 42 (EMA of squared deviations) - PS_STRIDE 41 -> 43 - All 6 hardcoded-stride sites migrated in lockstep Producer (experience_kernels.cu Flat branch): - Per-bar EMA update alpha=0.05 (matches Task 1 reward-ema convention) - Welford-style: delta = c - mean; var_ema = (1-alpha)*(var + alpha*delta^2) Consumer (experience_kernels.cu entering_trade block): - ratio = stddev/mean; stability = clamp(0, 1, 1 - ratio/0.2) - Fires only when ratio < 0.2 (stable pre-entry conviction) - bonus = shaping x vol_proxy x stability x conviction_core - All multiplicands in [0,1] except vol_proxy (<=0.01); max bonus ~ 0.01 - Mirrors B.2 novelty-bonus structure — one bounded shape replaced (novelty -> stability) - rc[5] += bonus; both EMA slots reset at entry, reversal, fold/episode boundary Per pearl_one_unbounded_signal_per_reward.md: exactly ONE unbounded multiplicand (vol_proxy); all others bounded. No `q_scale x |reward|` style blowout possible. No new ISV slot. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
ml
10-model ML ensemble for the Foxhunt HFT system, built on Candle v0.9.1.
Models
- DQN (Rainbow) — deep Q-network with prioritized replay, dueling heads, noisy nets
- PPO — proximal policy optimization with GAE, LSTM policies, clip-higher
- TFT — temporal fusion transformer for multi-horizon forecasting
- Mamba2 — state space model for sequence prediction
- Liquid Networks — biologically inspired networks for non-stationary data
- TLOB — transformer-based limit order book analysis
- KAN — Kolmogorov-Arnold networks
- xLSTM — extended LSTM architecture
- TGGN — temporal graph neural network
- Diffusion — diffusion-based generative model
Key Modules
ensemble— model ensemble coordination and confidence aggregationhyperopt— PSO-based hyperparameter optimization with per-model adapterstrainers— unified training loops (DQN, PPO, supervised)inference—InferenceAdaptertrait for predictioncheckpoint— model checkpointing and restorationevaluation— walk-forward evaluation pipeline
Usage
use ml::dqn::DQN;
use ml::ppo::PpoTrainer;