v0.1.7: Normalize trainer profile payloads to one stable schema
Pre-release
Pre-release
Move the canonical simple-profiler shape into TrainingHistory so profile payloads are normalized consistently whether they come from a fresh fit, a restored history state, or future checkpoint-driven reconstruction. Missing counters now default cleanly, derived values are recomputed, and malformed profile sections fail with explicit ValueError messages. Constraint: The simple-profiler key order and required fields are already part of the repo's documented contract Rejected: Keep profile schema logic only inside Trainer | leaves restored history payloads unsanitized and allows shape drift across entry points Confidence: high Scope-risk: narrow Reversibility: clean Directive: Keep TrainingHistory and Trainer on one shared profile schema source; do not duplicate profiler key lists in multiple modules again Tested: python -m ruff check vgl tests/train; python -m mypy vgl; PYTHONPATH=. pytest -q tests/train/test_history.py tests/train/test_trainer_plus.py -k "profile or profiler or history" Not-tested: Full repository pytest on this branch; resume flows that persist a completed profile and then continue training