From 7b13eb0eca515683ea2c596505cebfb07c84f40a Mon Sep 17 00:00:00 2001 From: Daniel Han Date: Wed, 12 Feb 2025 16:19:13 -0800 Subject: [PATCH] Update rl_replacements.py --- unsloth/models/rl_replacements.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unsloth/models/rl_replacements.py b/unsloth/models/rl_replacements.py index a101d35a04..9405fef577 100644 --- a/unsloth/models/rl_replacements.py +++ b/unsloth/models/rl_replacements.py @@ -143,6 +143,6 @@ def grpo_trainer__move_model_to_vllm(function_name, function): # .*? matches first match. .+? matches final match. function = "def _move_model_to_vllm(*args, **kwargs): return None\n" - return function + return function.find("def") * " " + function pass RL_FUNCTIONS["grpo_trainer"].append(grpo_trainer__move_model_to_vllm)