r/LocalLLM • • 4h ago

Discussion Those coding locally with Qwen: which CLI are you using?

Running a local AI server with an RTX 4090. Just upgraded to Qwen 4 and have been using it through Claude Code.

Works pretty well overall. Main annoyance is that I’ve had to cap the context at ~131k and it compacts super frequently.

Other than that can’t really complain. MCPs/web search and all the usual stuff works.

For those also using Qwen locally for coding, which CLI are you using? Happy with your setup?

3 Upvotes

14 comments sorted by

5

u/my_name_isnt_clever 4h ago

Pi. I like to keep it simple.

1

u/ConstantinSpecter 4h ago

Did you try other CLIs or was Pi your first pick? If so, why?

1

u/my_name_isnt_clever 4h ago

Yeah, I started with Aider pre-Claude Code, then Mistral Vibe, OpenCode briefly but I didn't like it, and now Pi.

My preferred approach is the opposite philosphy of CC and the cloud models. I want to be close to the model, manage every token in it's system prompt myself, and leave out anything I don't need. I had my agent write a couple Pi extensions for that additional functionality I want, and now it's my ideal harness.

2

u/bytejuggler 4h ago

pi.dev , omp.sh or opencode.ai (why are you capping context so low?)

1

u/ConstantinSpecter 4h ago

Thanks! Will check those out.

Context is low not by choice but VRAM. On a single 4090 I have 24GB. Qwen4 35B at IQ4_XS uses ~19 GB, context costs me roughly 1.3 GB per 100k tokens. Together with vision enabled I get about 140 tok/s. Above that llama.cpp starts moving expert weights to the CPU and it drops to like 100 tok/s at 196k. Text-only I could fit about 160k.

131k is the biggest window that keeps full speed with vision

2

u/DeathGuppie 4h ago

Drop some your experts to CPU. Only 3 billion of the 35 billion are active, at any given moment. Moving enough of those experts into RAM to give you at least twice that context wouldn't even be noticeable in speed.

1

u/sicmek 4h ago

Maybe I understand you wrong, but why don't you split the model between vram and ram? With 24gb vram you should be able to run a pretty big quant.

And for your context problem: At how many tokens does the compaction start? In opencode you define the context length in the config, so maybe claude code starts a bit early with compaction?

2

u/Slight-Living-8098 4h ago edited 4h ago

Pi. It's my favorite out of all of them.

With llama.cpp and Qwen4 you can put the ngram table all in system ram and bump your context up. I'm running 262144 context with Unsloth's UD-IQ4_XS and the FP8 ngram table in system RAM on my RTX 4090. I also put the mmproj in the system RAM

2

u/DeathGuppie 4h ago

I use pi, but I'm going to be honest. It's a do it yourself toolbox. If you just want plug and play I'd lean more towards opencode. If you want something more agentic, doing financial, office stuff. Hermes is probably better.
The big thing about pi is that like any other customized solution it becomes what you want. The other options are more ready to go.

1

u/ferrx 4h ago

Only qqstudio. Biased because it’s my pet project, but it works great for my workloads.

1

u/romeozor 4h ago

OpenCode v2 with a Pi agent.

You always read how much token overhead OpenCode's default Build agent has (I personally have my doubts, plus once you start with MCPs you're just throwing tokens out the window, but you know, FOMO), and how amazingly lightweight Pi is, so I asked Claude to look up Pi harness' system prompt and make a pi.md agent for me in OpenCode.

Pi harness is probably fine too

1

u/wwwyzzrd 3h ago

i only make my own cli over and over.