Skip to content

fix: reject non-positive rollout temperature at parse time - #2297

Merged
zhuzilin merged 1 commit into
THUDM:mainfrom
EazyReal:fix/reject-zero-rollout-temperature
Aug 21, 2026
Merged

fix: reject non-positive rollout temperature at parse time#2297
zhuzilin merged 1 commit into
THUDM:mainfrom
EazyReal:fix/reject-zero-rollout-temperature

Conversation

@EazyReal

Copy link
Copy Markdown
Contributor

Problem

--rollout-temperature 0 is greedy decoding. That is not a usable on-policy RL policy: the sampling distribution is a delta, while log-probs (and PPO ratios) still come from a softmax. Greedy RL should be rejected at config parse, not assumed away in loss code.

--eval-temperature 0 is unchanged; greedy eval remains valid.

Change

slime_validate_args raises if rollout_temperature <= 0.

Test plan

  • tests/test_megatron_argument_validation.py0.0 and -0.1 raise; existing validate-args cases still pass at the default 1.0

Made with Cursor

Greedy T=0 is not a usable on-policy RL distribution. Fail in
slime_validate_args instead of special-casing it later in logprob math.
Eval can still use --eval-temperature 0.

Co-authored-by: Cursor <cursoragent@cursor.com>
@zhuzilin
zhuzilin merged commit 16c15fc into THUDM:main Aug 21, 2026
63 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants