Qwen3.8-27B-CAN: a 27B model in 7 GB that runs usefully on a 4-core CPU

Unofficial derivative of Qwen/Qwen3.8-27B (Apache-2.0). It is not affiliated with or endorsed by Qwen or Alibaba.

CAN is an additive nibble code:

  • Each group of 8 weights is the sum of 4 codewords, one from each of 4 codebooks of 16 entries.
  • The weights are rotated by a block Hadamard transform (blocks of 512), with one fp16 scale per (row, 512 columns).
  • Decoding is table lookups (pshufb), so the CPU kernel is fast.

The file was made in two stages: post-training quantization (PTQ), then a short knowledge distillation against the bf16 model that tunes only the scales and norms. The codes, codebooks and file size do not change.

Files

file what size bits/weight (whole file)
Qwen3.8-27B-CAN-kd.gguf recommended: PTQ + KD 7.0 GB 2.046
Qwen3.8-27B-CAN.gguf PTQ only 7.0 GB 2.046
can3.patch llama.cpp patch with the CAN types (CPU only)
ptq/, ptq_mtp/, kd/delta.npz the codes and the KD scales, to rebuild the GGUF
resultados/ logs, pre-registration and full report (in Portuguese)

Results

model bits/weight GSM8K (N=1319) share of bf16 CPU generation tg128 (t/s) CPU prompt pp512 (t/s)
bf16 original 16 0.889 100 % โ€” โ€”
CAN + KD (this repo) 2.05 0.876 98.6 % 5.75* 9.84*
CAN, PTQ only 2.05 0.825 92.8 % 5.75 9.84
our earlier ECTV/IQ2 file, with KD (FardoX/Qwen3.8-27B-rapido-GGUF) 1.99 0.870 97.9 % 2.57 8.28
Q4_0 (--pure) 4.51 โ€” โ€” 3.25 5.87
  • CPU: 4 vCPU (AMD EPYC 9655), binaries built for AVX2 only, llama-bench -t 4. Each figure is the median of 3 VMs. Generation is 1.77ร— Q4_0 (range 1.63โ€“1.80) and 2.26ร— the ECTV file.
  • *KD file speed: speed was measured on the PTQ file. The KD file uses the same tensor types and kernels (only scale values differ), so the speed should be the same. We did not re-measure it.
  • GSM8K: same harness for all rows, greedy decoding, max 768 tokens. The CAN rows ran on an exact F16 emulation of the CAN weights on GPU (A100). The bf16 and ECTV rows ran on an H100 on 22/11.
    • Integrity check on CPU: the real CAN kernels give WikiText-2 PPL 7.847, against 7.881 for the emulation (0.4 % apart).
  • Calibration and KD data: C4 train plus text generated by the bf16 model. No GSM8K test and no WikiText data were used in calibration or KD.

Honest caveats

  • One run per configuration, with no repeated seeds. The GSM8K 95 % CI is about ยฑ1.8 points.
  • The bf16 and CAN GSM8K numbers come from different GPUs (H100 vs A100). Greedy decoding is close to deterministic, but not exactly across hardware.
  • Speed on other CPUs will differ. On a larger AVX-512 server in a related test (Llama-2-7B), CAN's generation lead shrank to about 1.9ร—, and its prompt speed was below IQ2.
  • Text only. We did not test vision. The MTP layer is in ptq_mtp/ but is not used by the GGUF.

Run (CPU)

git clone https://github.com/ggml-org/llama.cpp && cd llama.cpp
git checkout ad9d9e8f50e6ff9a6bfbbdd3aef6d74a8428cf4e && git apply ../can3.patch
cmake -B build -DGGML_CUDA=OFF -DGGML_NATIVE=ON -DLLAMA_CURL=OFF && cmake --build build -j --target llama-cli llama-server
./build/bin/llama-server -m ../Qwen3.8-27B-CAN-kd.gguf -c 8192 -ngl 0

Stock llama.cpp cannot load these files. There are only CPU kernels (x86 AVX2): no CUDA, no Metal, no ARM.

Downloads last month
437
GGUF
Model size
27B params
Architecture
qwen35
Hardware compatibility
Log In to add your hardware

We're not able to determine the quantization variants.

Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for FardoX/Qwen3.8-27B-CAN

Base model

Qwen/Qwen3.8-27B
Quantized
(1,973)
this model