Safetensors
French
English
nemotron
openllm-france

Prime the opening <think> in the generation prompt and remove enable_thinking

#2
by Jeronymous - opened
OpenLLM France org

Two changes to the chat template's generation prompt:

1. Prime the opening <think> tag. The generation prompt now ends with <|im_start|>assistant\n<think>\n instead of a bare <|im_start|>assistant\n. The model starts generating inside the reasoning block, so it no longer has to emit the opening <think> itself — which it sometimes failed to do (missing opening tag, or a malformed/duplicated </think>), especially when prior-turn reasoning is stripped from the history via preserve_thinking=false. This matches the approach used by current Qwen3 thinking templates. Note: the model's output now contains only the closing </think> (the opening tag is in the prompt); reasoning parsers should expect the primed opening tag, which is standard for Qwen3-style thinking models.

2. Remove the enable_thinking option. On this thinking model, enable_thinking=False did not reliably disable reasoning (the model still reasons out loud and can emit a stray </think>), so the empty-think-block branch is removed. Passing enable_thinking=... is now simply ignored. For a non-thinking model, use Luciole-8B-Instruct-1.1 (the README is updated accordingly).

History rendering (including preserve_thinking) is unchanged.

Ready to merge
This branch is ready to get merged automatically.

Sign up or log in to comment