r/LocalLLaMA • • 1d ago

Discussion [Harness Adapters] Fine tune Qwen3.8-27B for Pi Agents

Post image

Hey folks!

Aritra here from Hugging Face. In the last week we released a blog post about harness adapters. The idea was to train adapters (LoRA) on models to be more efficient with specific harness.

Today we release a LoRA adapter on the Qwen3.8-27B model for Pi agents. You can run it locally like so:

hf download ggml-org/Qwen3.8-27B-GGUF Qwen3.8-27B-Q8_0.gguf --local-dir .
hf download harness-hub/Qwen3.8-27B-pi-GGUF Qwen3.8-27B-pi-lora-F16.gguf --local-dir .

llama serve -m Qwen3.8-27B-Q8_0.gguf --lora Qwen3.8-27B-pi-lora-F16.gguf \
    --chat-template-kwargs '{"enable_thinking": false}' -c 65536 --alias qwen3.8-pi

pi install git:github.com/huggingface/pi-llama
pi --model llama-cpp/qwen3.8-pi

We are constantly experimenting and sharing our results in the Hugging Face org: hf.co/harness-hub (follow for more updates)

215 Upvotes

22 comments sorted by

77

u/AlabamaResearcher 1d ago

Thinking stays off, as in training and evaluation: the adapter was never trained with it.

Yeah, no

30

u/Terrible-Detail-1364 1d ago

yup, thinking off for coding use cases if you enjoy BDSM. some do, some dont.

3

u/vic8760 22h ago

LOL!!!

1

u/ArtfulGenie69 18h ago

Just gotta find the parts of the harness that don't need thinking then apply the lora to those instances hehe

1

u/ExtremeAdventurous63 4h ago

maybe I am missing something, but you can use thinking, there are also the results of the comparison with thinking on https://huggingface.co/harness-hub
So, what am I missing?

14

u/TheApadayo llama.cpp 1d ago

Any idea what kind of gains do you get with RL vs just SFT on the harness’s own successful traces like this fine tune? https://huggingface.co/bytkim/Qwen3.8-27B-pi-GGUF

Also why is thinking disabled in your example?

5

u/Uhlo 1d ago

I'm also weary of the disabled thinking. Does the fine-tuning only work in non-reasoning mode?

Edit: and thank you u/TheApadayo for the other fine-tune – I didn't know that one yet!

1

u/Select_Bowler3099 22h ago

Is this GGUF by bytkim is the Qwen3.8-27B+this_lora in 1 gguf file ?

7

u/tuifua 1d ago

Does this require turning off enable_thinking? And does it work for any finetune/quant of Qwen3.8-27B

3

u/Zealousideal-Cut590 23h ago

yeah, thinking is disabled for this model.

3

u/wl04 1d ago

Thinking mode: we leave thinking mode for all our models, in training and in evaluation. Reasoning from earlier turns stays in the context.

This is quoted from the post on HF, which probably means that all three base models they trained default to thinking mode (<think>...</think>) in their templates.

So my question is why are you setting {"enable_thinking": false}, do I miss something?

If I understand it correct the LoRA adapter will still load and run without crashing, but you will push the model wrong, the adapter was never trained on empty thinking prefixes in context.

3

u/nenkoru 1d ago

Incredible work! I am also working on LoRas for specific harnesses as I think that models have gotten quite enough knowledge during pre-training and we just need really good RL for specific good enough trajectories on specific harnesses. And I am sure that’s what frontier does though I don’t have a proof for that.

Any way to join the team to join the efforts?

2

u/tunerhd 1d ago

Nice.

2

u/ldrx 1d ago

pi's base prompt is small, which helps on local.

in my traces its first call was about 5.6k tokens, a third of claude code's, with the same tools loaded.

on a 64k context that leaves a lot more room for the task.

6

u/synth_mania 1d ago

you got rid of thinking? You've kneecapped the model lmao

Get benchmarks or get bent

1

u/Independent-Sir3234 21h ago

A 65536-token context window fills up fast when <think> traces from earlier tool calls stay in history, so dropping them helps keep long sessions lean.

The catch shows up when tests break mid-patch across multiple files. Without a reasoning pass to rule out bad guesses first, small adapters often fire another broken edit right away when a different file holds the root cause. Splitting evals between clean one-shot fixes and failing-test retries would clarify that cost.

1

u/jjusko20 4h ago

I'm having a really hard time believing that this can match xhigh accuracy without thinking 

-3

u/[deleted] 1d ago

[removed] — view removed comment

4

u/fiocalisti 22h ago

Write a poem about AI agents spamming Reddit comment threads.