jclyons52/Qwen3.8-27B-UD-Q2_K_XL-MLX-kq-direct
Qwen3.8-27B UD-Q2KXL — MLX native IQ-quant (experimental)
2-bit dynamic IQ-quantized MLX build of Qwen3.8-27B, replicating unsloth's UD-Q2KXL GGUF bit-map (2.72 bpw, 9.5 GB) — quantized directly from the fp16 base with native non-linear IQ codecs (IQ1S/IQ1M/IQ2XXS/IQ2XS/ IQ2S/IQ3XXS/IQ3S/IQ4XS + K-quants) via mlx-kquant.
This is an experimental format. It requires mlx-kquant (which patches mlx_lm.load) and does not load with stock mlx-lm.
Per-tensor codec map (498 tensors)
Importance-weighted encoding uses unsloth's published imatrix (GGUF format, in_sum2/counts), with out-projection vectors un-permuted from llama.cpp's tiled V-head order back to HF grouped order.
Usage
pip install mlx-kquantfrom mlx_kquant.mlx_lm_patch import patch_mlx_lm_load
patch_mlx_lm_load() # must run before mlx_lm.load
from mlx_lm import load
model, tokenizer = load("jclyons52/Qwen3.8-27B-UD-Q2_K_XL-MLX-kq-direct")
response = generate(model, tokenizer, prompt="Hello", max_tokens=100)Quality (wikitext-2 first-32k, MLX harness, 512-token windows)
*window-0 numbers on the MLX harness for apples-to-apples; full-32k PPL for this build is ~14.8. The GGUF original measures 7.18 under llama.cpp's perplexity tool, but llama.cpp and MLX perplexity numbers are not directly comparable (~1.3 ppl harness offset measured on fp16).
Honest summary: usable, coherent output at 2.72 bpw, but not yet at llama.cpp's IQ2 quality — the ggml encoder inside mlx-kquant is older than the one unsloth used. See RESUME-NOTES.md in the ud2mlx repo for the parity chase.
Build provenance
- Base: unsloth/Qwen3.8-27B fp16 (local snapshot, 2026-08)
- Codec map + imatrix: unsloth UD-Q2KXL GGUF artifacts
- Encoder: mlx-kquant (ggml CPU IQ encoders, Metal dequant/matmul)
- Linear-attn tensors (Alog, dtbias, conv1d, V-head projections) all from the fp16 base in HF head order — never from the GGUF (different base revision; see repo notes).
