AstrAI/astrai/trainer
ViperEkura 2c7a71a9c0 refactor: separate old policy and ref model in GRPO strategy
- Split single ref_model into old_model (importance sampling ratio) and ref_model (frozen KL regularizer)
- Move ref_model/old_model creation from strategy __init__ to TrainContextBuilder, pass as explicit parameters
- Remove periodic sync_ref_model + sync_interval; add sync_old_model for external rollout loop to call
- DPOStrategy also receives ref_model from builder
- Fix std to use unbiased=False (population std per GRPO paper)
- Remove redundant tests (test_grpo_kl_zero_at_init, test_grpo_no_sync_interval_param)
- Remove --grpo_sync_interval CLI arg
2026-07-14 20:03:45 +08:00
..
__init__.py chore : 升级 torch 2.11.0+cu128,移除自定义 Muon,修复 gloo device_id 2026-06-27 16:10:37 +08:00
metric_util.py refactor : grad_norm 指标简化,clip_grad_norm 移至 executor 2026-06-30 14:59:43 +08:00
schedule.py fix: scheduler division-by-zero, loss_mask bool 2026-07-03 22:04:55 +08:00
strategy.py refactor: separate old policy and ref model in GRPO strategy 2026-07-14 20:03:45 +08:00
train_callback.py feat : add distributed checkpoint via executor checkpoint_context 2026-07-13 12:27:09 +08:00
train_context.py refactor: separate old policy and ref model in GRPO strategy 2026-07-14 20:03:45 +08:00
trainer.py refactor: merge validation into MetricCallback, simplify progress bar to optimizer steps 2026-07-03 21:43:08 +08:00