ML Training Pipeline
Train models to predict setup quality and edge.
Quick Start
python scripts/train_edge_model.py --symbol MNQ --timeframe 4h
# Or use skill
/train-model STRAT_02 --symbol MNQ --timeframe 4h
Features
| Category | Features |
| Pattern | sweep_quality, ob_quality, fvg_present, confluence_score |
| Time | hour_of_day, session, is_killzone |
| Context | atr_percentile, trend_strength, htf_alignment |
Models
| Model | Best For |
| LightGBM | Default, fast |
| XGBoost | Alternative |
| CatBoost | Categorical features |
Options
| Option | Description |
--model | Model type |
--cv | Cross-validation folds |
--deploy | Deploy after validation |
--compare | Compare vs production |
Output
outputs/models/STRAT_02/
├── model_v3.pkl # Trained model
├── model_v3.pkl.meta.json # Metadata
├── model_current.pkl # Production
└── model_report.md # Report
Validation
- Time-series split (no shuffle)
- Out-of-sample testing
- Overfitting detection
- Drift monitoring
Skill Usage
# Train and deploy
/train-model STRAT_02 --model lightgbm --deploy
# Compare to current
/train-model STRAT_02 --compare