Why do reasoning models return empty replies, cut off mid-thought, or loop on </think> tags?
Why do reasoning models return empty replies, cut off mid-thought, or loop on </think> tags?
Reasoning models spend output tokens on thinking before generating visible dialogue. In SillyTavern, Tavo, OMate, and JanitorAI, that thinking budget produces three recurring failures: empty message bubbles, replies truncated inside <think>, and repetition loops caused by unclosed </think> tags left in chat history.
1. Empty bubble or reply cut off mid-thought
Reasoning tokens count against max_tokens. When Max Response Length is set to 500–1000, the model can exhaust max_tokens inside <think>...</think> and stop before emitting visible dialogue.
- Set
max_tokensto4096–8192when calling reasoning models. Evenhy4-flash-freeuses roughly 230 reasoning tokens for a one-sentence reply and requiresmax_tokensof at least2000. - Enable streaming and point your client to
https://direct.beatapi.io/v1(orhttps://api-asia.beatapi.io/v1in Asia) so long thinking pauses do not hit Cloudflare’s 100-second wait limit. - Avoid setting
max_tokensto32000or higher on a small balance, because BeatAPI’s balance pre-check can reject oversized caps with402 insufficient_credits. See 402 error from oversized max_tokens.
2. Repetition loops from broken </think> tags
When a reasoning reply cuts off before closing </think>, or when a client sends raw <think> blocks back in chat history, the broken tag stays in subsequent prompts. The model then imitates the malformed tag structure and loops on reasoning text or earlier paragraphs.
- Edit or delete the broken turn: Remove any unclosed
<think>or stray</think>text from the last assistant message before sending the next turn. - Enable reasoning extraction: In SillyTavern’s Reasoning settings, enable automatic reasoning parsing so thinking blocks stay folded in the UI and stay out of subsequent prompt history unless you explicitly resend them.

