Model Releases
My agent kept randomly stopping mid-task and I finally figured out why (llama.cpp + Qwen3 tool calling)
Spent about two weeks convinced I had a prompting problem. My local Qwen3 agent would just stop. No error, no crash, finish_reason came back as 'stop' like the model had decided it was done. Except it
Spent about two weeks convinced I had a prompting problem. My local Qwen3 agent would just stop. No error, no crash, finish_reason came back as "stop" like the model had decided it was done. Except it clearly wasn't done, the task was half finished. Turns out the model was calling the tool the entire time. The call was just sitting inside the reasoning block, wrapped in tags, and never made it out into the tool_calls field the API is supposed to populate. From the outside it looks exactly like the model decided not to act. No error to grep for, no stack trace, the response comes back as a perfectly valid 200. Once I knew what to look for, I found the same thing reported separately against vLLM, SGLang, and llama.cpp, mostly with Qwen3, some DeepSeek. Nobody had tied it together as one bug class, everyone was just closing their own version of it as a one-off. I ended up writing a small library, unswallow, that sits between the provider response and the agent loop, detects when this happens, and rebuilds tool_calls from whatever's stuck in the reasoning field. JS and Python, no dependencies. Repo's here if anyone wants to poke at it: https://github.com/0DukePan/unswallow Mostly posting because I'd guess some of you running quantized reasoning models locally have hit this and just assumed it was a bad quant. If your agent ever goes quiet mid-task for no obvious reason, worth checking what's actually sitting in the reasoning field before blaming the model or the quant. submitted by /u/duke4rs [link] [comments]
Related
- Built a Mac app that actually uses Ollama for work, not just chat — with a calibration step for models with flaky tool calling
- Ollama + llama.cpp + VS Code + OWUI + ...cloud?
- I built a Windows GUI launcher to benchmark and manage multiple llama.cpp builds (useful for AMD GPU users juggling Vulkan/ROCm/HIP builds)
- Qwen3.8-27B on M1 Max 32GB: MLX 15.8 tok/s vs llama.cpp 9.7 tok/s - but llama.cpp prefill is faster
Source: r/ollama | 2026-09-10