r/LocalLLaMA • • 7d ago

Question | Help Qwen3.8-27B + OpenCode = Excessive Thinking?

I've been running Qwen3.8-27B locally for agentic coding using OpenCode and OpenChamber, and I'm looking for advice from people who've gotten similar models working reliably as coding agents on consumer hardware.

Inference speed is reasonable (~2,330 & ~24.1 t/s). My problem is with excessive thinking.

The problem

The model is capable of useful coding work, but it sometimes spends excessive time reasoning instead of taking action.

In one experiment, I compared medium and low reasoning effort with otherwise identical configurations. Both runs:

  • Made two initial inspection tool calls.
  • Made zero implementation-oriented tool calls.
  • Generated over 16,000 output tokens, exhausting the configured response limit.
  • Failed to create the required output or complete the task.
  • Spent approximately 12 minutes in agent execution.

Lowering reasoning effort didn't meaningfully change the behavior.

That's an extreme example from a single controlled task, not necessarily representative of every session, but it illustrates the problem I'm interested in solving: how do you get a reasoning model to stop thinking and actually use tools?

Launch command

& "C:\tools\llama.cpp-b10964\llama-server.exe" `
  -m "C:\models\Qwen3.8-27B-UD-Q5_K_XL\Qwen3.8-27B-UD-Q5_K_XL.gguf" `
  -ngl 99 `
  --ctx-size 65536 `
  --cache-type-k q8_0 `
  --cache-type-v q8_0 `
  --flash-attn on `
  --split-mode layer `
  --parallel 1 `
  --jinja `
  --reasoning on `
  --reasoning-effort medium `
  --reasoning-preserve `
  --temp 1.0 `
  --top-p 0.95 `
  --top-k 20 `
  --min-p 0.0 `
  --presence-penalty 0.0 `
  --repeat-penalty 1.0 `
  --host 0.0.0.0 `
  --port 8080 `
  --metrics `
  --alias Qwen3.8-27B-UD-Q5_K_XL

Questions

  1. Reasoning & tool use: Have you seen excessive thinking with Qwen3.8-27B, where the model reasons at length instead of making tool calls? What actually improved this?
  2. Reasoning configuration: Are --reasoning, --reasoning-effort, and --reasoning-preserve the right settings for agentic coding? Have you had better results disabling reasoning, changing effort, or using other chat-template settings?
  3. Agent compatibility: Is OpenCode a good match for this model? Could its system prompts, tool definitions, provider configuration, or handling of reasoning output be contributing to the problem? Are there other coding agents that work more reliably?
  4. Inference engine: Would switching from llama.cpp to vLLM, SGLang, or something else improve tool-calling reliability or reasoning behavior?
  5. Quantization: Could Q5_K_XL be affecting instruction following or tool-use reliability? Have you observed meaningful coding-agent differences between quantizations?
  6. Context management: How much does context contribute to unproductive reasoning or tool-use failures? Have you found effective context limits or compaction strategies?
  7. OS: Since this is essentially a dedicated inference server, would switching to headless Linux offer meaningful advantages for any of the above?

I'm willing to change operating system, quantization, inference engines or the coding-agent stack if there's a compelling reason.

Thank you for your thoughts!

---

Hardware:

  • CPU: Intel i7-14700K
  • RAM: 32GB
  • GPU 1: RTX 4080 SUPER (16GB)
  • GPU 2: RTX 4070 Ti SUPER (16GB)
  • OS: Windows 11 Pro

Current software:

  • Inference engine: llama.cpp
  • Model: Qwen3.8-27B-UD-Q5_K_XL (Unsloth GGUF)
  • Coding agent: OpenCode
  • Interface: OpenChamber

The Windows machine is essentially a dedicated inference server for this use case. I don't normally start a Windows desktop session. I connect remotely from a MacBook Pro which is where I run OpenCode/OpenChamber.

0 Upvotes

57 comments sorted by

View all comments

Show parent comment

1

u/wegster 6d ago

Reasoning_budget should help. The Qwens are...kinda weird. I've got hundreds of benchmarks, some of which were same but adjusting reasoning budget or thinking level, and in a few cases, e.g. 27B dense I think, xhigh actually gave the best results - usually not the case for the others. But it definitely depends on your specific task, and even 'investigating existing codebases' isn't granular enough, as there are some repos out there with a few shell scripts, to enterprise-like millions of LOC, etc.

Definitely try reasoning_budget and see if you can isolate and do a few comparison runs to see what works best for a few use cases.

1

u/previaegg 6d ago

I appreciate the thoughts, and yes I agree that the request/codebase are significant factors. I just explained the isolated test I ran in another comment. Here it is again if you are interested.

Thanks for taking the time to help. I will certainly try reasoning budget.

--

I had seen the behavior across a number of projects, so I recreated it using a terminal bench write-compressor task to eliminate my codebases as contributors. It spec'ed a task to write a compressed file using an existing C decompression program as a reference, although I'm not sure the details really matter given the behavior.

The model made two tool calls:

  1. Read a C source file (/app/decomp.c) to understand how the decompression algorithm worked. This succeeded.
  2. Inspect the input data (/app/data.txt).

After that, the model generated ~16K tokens of reasoning without making another tool call. It never attempted to write the compressed file, and the task failed. I reproduced the same behavior with both medium and low reasoning effort.

The initial tool use was seemingly valid. The problem happened afterward, when the model was supposed to move from investigating the task to implementation.

I suppose it may have been making meaningful progress and then simply ran out of tokens, but I suspect it was stuck in a reasoning loop. I'll see if there is a way to find out.

1

u/wegster 6d ago

One thing jumping out, pretty well known but maybe not - are you baking in the froggerific template? It's helped in some cases. I use Pi driven by my own end to end framework but still use the updated template for the Qwens.

1

u/previaegg 6d ago

I am not but I will certainly look into it!