Skip to content
NetProjects
Menu

Insights

harness-hub's Qwen3.8-27B for the OpenCode agent on a Mac: MLX and GGUF builds

NetProjects

harness-hub trained a LoRA adapter for Alibaba Cloud's Qwen3.8-27B with reinforcement learning (AsyncGRPO in TRL), so that it works as the model behind the OpenCode coding agent on software-engineering and terminal tasks. harness-hub reports SWE-bench Pro (hard 51) rising from 35.3% to 51.0% and Terminal-Bench 2.1 from 46.4% to 52.4% against the base model, and says that with thinking off the adapter matches the base model thinking at its highest effort while generating 6 to 8 times fewer tokens per task. These are harness-hub's figures, from runs under OpenCode with thinking off; we have not reproduced them.

We merged the adapter into Qwen3.8-27B, kept the vision encoder and Qwen's own multi-token-prediction (MTP) layer, and published ready-to-run builds for Macs with Apple Silicon (MLX) and for llama.cpp (GGUF), plus the adapter on its own for mlx-lm. Everything is under the Apache-2.0 licence. A sister port does the same for the pi agent: https://netprojects.com/insights/harness-hub-qwen3-8-27b-pi-adapted-coding-agent-mlx-gguf

Always up to date. We keep these builds current on Hugging Face. When harness-hub releases a new version of the adapter, we rebuild, re-test and publish it there, so the links on this page always point to the latest version. The numbers in this article were measured on the version named in each section; the model cards on Hugging Face carry the current figures.

What we released

Merged from harness-hub's adapter at revision b4171c0 and Qwen3.8-27B at revision 3756181. The MLX builds were converted with mlx-vlm; the quantised ones use affine quantisation with group 64.

Hugging FaceSizeSame next token as bf16KL vs bf16
netprojects/Qwen3.8-27B-opencode-adapted-MLX-6bit (recommended)23.1 GB98.7%0.0014
netprojects/Qwen3.8-27B-opencode-adapted-MLX-8bit30.0 GB99.2%0.0004
netprojects/Qwen3.8-27B-opencode-adapted-MLX-4bit16.3 GB96.7%0.0203
netprojects/Qwen3.8-27B-opencode-adapted-MLX-bf1655.6 GBreferencereference
netprojects/Qwen3.8-27B-opencode-adapted-MLX-adapter638 MBLoRA only, for mlx-lmon any Qwen3.8-27B MLX build

The GGUF repository, netprojects/Qwen3.8-27B-opencode-adapted-GGUF, has Q6_K (22.4 GB, recommended), Q8_0 (29.0 GB) and Q4_K_M (16.8 GB), each with the MTP layer, plus a 0.9 GB vision projector for image input. Compared with the BF16 GGUF, they pick the same next token on 98.7%, 99.5% and 94.2% of positions.

How well it matches the original

Measured on 18 November 2026, MacBook Pro M5 Max (128 GB), with mlx 0.32.4, mlx-lm 0.32.2 and mlx-vlm 0.7.11.

  • Merge: all 256 adapted modules equal the base weight plus 2.0 times the LoRA product, rounded to bf16, checked element by element against an independent float64 computation. Every other tensor is the same as in Qwen3.8-27B, byte for byte.
  • Quantisation: each quantised MLX build is exactly the affine (group 64) quantisation of the bf16 build.
  • Agreement with bf16, over 949 teacher-forced positions from 12 short prompts with thinking off: 8-bit 99.2%, 6-bit 98.7%, 4-bit 96.7%.
  • Tool calling: with the included chat template and thinking off, the 8-bit, 6-bit and 4-bit MLX builds and the three GGUF files each produced a well-formed bash tool call on an agent-style prompt.
  • Coding: three short Python tasks run against asserts, 3 of 3 on each of the 8-bit, 6-bit and 4-bit MLX builds.
  • Vision: the builds named the shapes and colours in a test image correctly.
  • Source files: every file of both pinned upstream revisions matches the Hub's SHA-256 hashes.

Speed

Greedy decoding, thinking off, 5 prompts of 256 tokens each from GSM8K, MATH-500, HumanEval, MBPP and MT-Bench, with other services running on the Mac, so treat these as indicative. MTP uses Qwen's own multi-token-prediction layer, included in every build. DSpine is Tencent's drafter for Qwen3.8-27B, which we ported earlier: https://netprojects.com/insights/dspine-speculative-decoding-qwen3-8-27b-mlx

MLX buildPlainMTPDSpine
4-bit33 tok/s62 tok/s (×1.91)73 tok/s (×2.29)
6-bit20 tok/s21 tok/s (×1.04)60 tok/s (×2.72)
8-bit17 tok/s37 tok/s (×2.15)54 tok/s (×3.03)

With llama-server and MTP turned on, the GGUF files went from 27 to 53 tokens per second (Q4_K_M), 22 to 46 (Q6_K) and 18 to 43 (Q8_0).

Try it

Keep thinking off: the adapter was trained and evaluated that way. On a Mac with Apple Silicon, serve it with mlx-lm's OpenAI-compatible server and point OpenCode at it through the Chat Completions API:

pip install -U "mlx-lm>=0.32.2"
mlx_lm.server --model netprojects/Qwen3.8-27B-opencode-adapted-MLX-6bit --port 8000 \
  --chat-template-args '{"enable_thinking": false}'

The model card has the OpenCode configuration, image input with mlx-vlm and the MTP and DSpine commands: https://huggingface.co/netprojects/Qwen3.8-27B-opencode-adapted-MLX-6bit. The GGUF card has the llama.cpp commands: https://huggingface.co/netprojects/Qwen3.8-27B-opencode-adapted-GGUF

Honest limits

  • All figures come from one machine, with other services running, so the speeds are indicative.
  • We did not run SWE-bench Pro, Terminal-Bench or any other agent test suite on these builds, so the agent scores above are harness-hub's, from its own setup.
  • Our checks are short: 12 prompts for agreement, one tool-calling prompt and three coding tasks.
  • On the 6-bit MLX build, MTP gave little or no speed-up in our run; DSpine did.
  • The 4-bit builds differ more from the bf16 weights than the others.
  • We have no memory figures beyond the file sizes above.

Licence

Qwen3.8-27B, harness-hub's adapter and our builds are all under the Apache-2.0 licence. Each of our repositories carries the licence text and a notice that describes the conversion and credits harness-hub and the Qwen team (Alibaba Cloud).

Links

Always up to date. We keep these builds current on Hugging Face. When harness-hub releases a new version of the adapter, we rebuild, re-test and publish it there, so the links on this page always point to the latest version. The numbers in this article were measured on the version named in each section; the model cards on Hugging Face carry the current figures.

Credits

The adapter is by harness-hub; Qwen3.8-27B is by Alibaba Cloud's Qwen team, under the Apache-2.0 licence. The MLX and GGUF builds are by NetProjects (Internet Projects Ltd). Not affiliated with harness-hub or Alibaba Cloud.

This article was drafted with AI assistance, then edited and approved by people on our team. You can read more about how we use AI at https://netprojects.com/standards/ai.