diff --git a/unsloth/models/rl.py b/unsloth/models/rl.py index c8602d31b2..f754fa953c 100644 --- a/unsloth/models/rl.py +++ b/unsloth/models/rl.py @@ -450,7 +450,7 @@ def _patch_trl_rl_trainers(trainer_file = "grpo_trainer"): pass # Check if SamplingParams is in there - if "SamplingParams" in RLTrainer_source: + if "SamplingParams" in old_RLTrainer_source: RL_pre = RL_pre + "\n" + inspect.getsource(vLLMSamplingParams) pass