From ca36bd6eb637d9f99b1d459dfb74406bf4eb03d0 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Wed, 18 Mar 2026 07:21:31 -0700 Subject: [PATCH] API: Remove leading spaces from post-reasoning `content` --- modules/reasoning.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/reasoning.py b/modules/reasoning.py index bc61aab3..9c92719b 100644 --- a/modules/reasoning.py +++ b/modules/reasoning.py @@ -79,7 +79,7 @@ def extract_reasoning(text, html_escaped=False): else: content_start = end_pos + len(end_esc) - return text[thought_start:thought_end], text[content_start:] + return text[thought_start:thought_end], text[content_start:].lstrip() # Handle standalone GPT-OSS final channel marker without a preceding # analysis/commentary block (the model skipped thinking entirely).