# quant **Repository Path**: chenchengf/quant ## Basic Information - **Project Name**: quant - **Description**: No description available - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-08-07 - **Last Updated**: 2026-08-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # Quant Framework A-share quant research framework. See `docs/superpowers/specs/2026-08-04-quant-framework-design.md` for design. ## Install ```bash pip install -r requirements.txt ``` ## Usage ### Run tests ```bash pytest ``` ### Run a backtest ```bash python jobs/run_backtest.py \ --strategy momentum_top20 \ --start 2024-01-01 --end 2026-07-31 \ --output reports/momentum.html ``` ### ML strategy (LightGBM) Three-step flow: train → backtest → signal. ```bash # 1. Train (once per model version, ~5-30 min depending on data size) python jobs/train_model.py \ --train-start 2021-01-01 --train-end 2023-12-31 \ --label-horizon 5 \ --output models/lightgbm_v1 # 2. Backtest python jobs/run_backtest.py \ --strategy lightgbm \ --start 2024-01-01 --end 2026-07-31 \ --model-path models/lightgbm_v1 # 3. Daily signal python jobs/daily_signal.py \ --strategy lightgbm \ --model-path models/lightgbm_v1 ``` Training prints val IC (Spearman rank correlation between predicted and realized 5-day returns). Rule of thumb: IC ≥ 0.02 weak, ≥ 0.05 medium, ≥ 0.08 strong. Below 0.02 → warning printed but model still saved. Models live under `models//` (gitignored). Each contains `model.pkl` and `meta.json` (train dates, feature list, metrics). ### Generate daily signal ```bash python jobs/daily_signal.py --strategy momentum_top20 ``` ### Refresh data ```bash python jobs/daily_update.py ``` ### Install crontab ```bash crontab jobs/crontab.example ``` ## Project structure See `docs/superpowers/specs/2026-08-04-quant-framework-design.md` section 4.