You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Browse filesBrowse the repository at this point in the historyBrowse files
Roja Reddy Sareddy
committed
fix(train): surface required hyperparameters instead of dropping them
FineTuningOptions.to_dict() builds the hyperparameters dict from
self._specs but omits any None value. A spec marked required=True with
no default that the user never set was therefore silently dropped from
the training request, so a job could launch missing a required
hyperparameter and only surface the problem via bad/failed results.
Add FineTuningOptions.required_keys() and have the shared
_validate_hyperparameter_values() raise a clear error listing any
required hyperparameter missing from the final (post recipe/override
merge) request. The check is opt-in via an options arg passed only at
the post-merge leaf-trainer call sites (SFT/DPO/RLVR/RLAIF/MultiTurnRL);
the pre-merge base_trainer call is left unchanged to avoid false
positives. Guarded on the concrete type so mocks are ignored.
Adds unit tests for required_keys() and the surfacing behavior.
0 commit comments