Per spec §6.4. Pure-CUDA kernels in baseline_kernels.cu — single cubin, 4 extern "C" __global__ functions sharing a templated compute_baseline_sharpe helper. Trunk-shared baselines (random_dir_kelly slot 411, aux_only slot 413, mag_quarter_fixed slot 414, trail_only slot 415) deferred to Task 1.4.b follow-up — they need partial-policy-forward access from the main eval pass. ISV slots written: 409 (buyhold), 410 (hold_only), 412 (naive_momentum), 416 (naive_reversion). Slots 411/413/414/415 stay at sentinel 0.0 until follow-up commit. Per established Phase 1 precedent: kernels + launchers land first; per-eval-pass launches + HEALTH_DIAG baseline_deltas emit deferred to follow-up commit per feedback_no_partial_refactor. Anchor tests: buyhold positive on +drift, hold_only emits 0, momentum + reversion sum near zero on mean-reverting series. 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;