inja
At this part here:
{%- set thinking_text = message.get('reasoning') or message.get('reasoning_content') -%}
{%- if thinking_text and loop.index0 > ns_turn.last_user_idx and message.get('tool_calls') -%}
{{- '<|channel>thought\n' + thinking_text + '\n<channel|>' -}}
{%- endif -%}
This looks at the current message being rendered and checks if it's more recent than the last user message and contained a tool call. If so, that means it's part of the current tool call chain and its thinking is added back into the message for interleaved thinking. For every other message, the "reasoning_content" field is ignored and thus the thinking is stripped.
Some frontends still need to catch up with the fact that modern models expect the "reasoning_content" field to be passed back for all messages so that the chat template can process the reasoning and decide what to keep and what to strip. Right now a lot are still trying to mess with it themselves by either throwing the reasoning straight into the "content" field of the message (OWUI, ST with the include previous thinking option) or just excluding it (ST by default), both of which are wrong.
However, this is not really a concern if all you're doing is roleplaying without much tool use. For normal chatting and roleplaying, you're getting the full intended experience from your model in ST by just letting it strip the thinking.