Issues with reasoning content and Open WebUI

#5
by zettabomb - opened

I mentioned this on the Reddit announcement post but I've tested it a bit more and figured here was a better place for it.

I was previously using the UD-Q4_K_XL quant of DeepSeek-V3.1-Terminus with ik_llama.cpp and getting good results, with Open WebUI as the frontend. Switching to DeepSeek-V3.2 (still at UD-Q4_K_XL) causes issues with the reasoning content, however. One way or another, Open WebUI doesn't "see" the starting tag and just puts the reasoning content in as regular text, including the closing . Using the V3.1-Terminus chat template with V3.2 seems to work, but then breaks tool calling support. Upon investigation, ik_llama.cpp reports that the actual prompt_tokens are identical - for my standard test prompt I see exactly "<|begin▁of▁sentence|><|User|>What is the airspeed velocity of an unladen swallow?<|Assistant|>" regardless of chat template.

I don't immediately see a reason for the discrepancy. It seems as if potentially it's an issue with ik_llama.cpp's internal parsing of the output into JSON, but it could equally be with Open WebUI's parsing, or with the chat template. Anything I can try to fix this?

With ud-q3k I also see that the thinking process is bleeding into the answer:

"Hmm, the user just said "Hello," which is a simple greeting. This doesn't require any complex analysis or deep thought.
I should respond warmly and professionally to set a positive tone for the conversation. Since this is an initial greeting, it's best to keep it friendly and open-ended to encourage further interaction.
A straightforward "Hello!" with an offer of assistance seems appropriate here. No need to overcomplicate it.Hello! How can I assist you today?"

This (including the same text but in Chinese, even when the same "Hello" prompt) happens to me with both Open Webui and llama.cpp's own UI and with llama.cpp and ik_llama.cpp.

"Hiding" the thinking process works fine in other models (kimi-k2.5, glm-4.7-flash, etc)

About the chat template from Terminus, doesn't that disable thinking? because I've just tried it and while I don't see the thinking process, I also don't see a way to show it, so I think "thinking" is disabled by it.

•
This comment has been hidden (marked as Resolved)

Hi haoshenghan,
yes, I always use "--jinja" in all Unsloth's quants.

About the chat template, that's how I tried and it just disabled reasoning. So yes, I don't see I thinking block... because there is no thinking :D

What inference engine and UI, and quant are you using? Because I tried with llama.cpp's own UI and I have the same issue (also with ik_llama.cpp), but only with this model.

•
This comment has been hidden (marked as Resolved)

So, I have already tried using the V3.1 template. It does seem to work ok, and I edited it to turn on thinking by default (although I think that can also be done with a CLI argument). I don't think it works correctly with tools though. Did they change their tool calling format?

Sign up or log in to comment