Commit d89537f
fix: ignore empty string reasoning_content in _extract_reasoning_from_additional_kwargs
Some providers (e.g. Groq) include "reasoning_content": "" in
additional_kwargs even when no reasoning was produced. The previous
check `reasoning_content is not None` treated an empty string as valid,
inserting an empty ReasoningContentBlock into the message content list.
Change to a truthy check so empty strings are skipped.
Fixes #36194
Co-Authored-By: hlwz5735 <12751178+hlwz5735@users.noreply.github.com>1 parent acc5498 commit d89537f
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
41 | | - | |
| 41 | + | |
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| |||
0 commit comments