Ternary Transformer:27B模型仅5.9GB
Now you can grow Bonsai on your potato
推荐理由
硬核量化实践,展示了极低比特下保持推理能力的工程方案,参数与性能数据详实,适合本地部署开发者参考压测。
No more excuses for GPU-poor folks not to start LLMing!
别再为 GPU 资源匮乏的人无法开始大语言模型(LLM)推理找借口了!
Full 27B-class reasoning in ternary transformer weights, for llama.cpp (CUDA, Metal, CPU)
在 llama.cpp(CUDA、Metal、CPU)中,使用三元变换器权重实现完整的 27B 级别推理能力
~9.3x smaller than FP16 (ideal) | 98.2% of FP16 intelligence retained | ~47 tok/s on an Apple M5 Max laptop
比 FP16(理想情况)小约 9.3 倍 | 保留 98.2% 的 FP16 智能水平 | 在 Apple M5 Max 笔记本电脑上约 47 tok/s
Highlights
亮点
- ~5.9 GB language model (down from ~54 GB FP16) — full 27B-class reasoning on a standard laptop or a single GPU
- 98.2% of FP16 intelligence retained: 84.78 average across 14 thinking-mode benchmarks — far above the conventional IQ2_XXS build (72.59) at about 82% of its footprint, and within 0.4 points of UD-Q4_K_XL at three times the footprint
- Retains thinking, reasoning, and agentic behavior deep in the sub-4-bit regime, where conventional low-bit representations collapse: math within half a point of full precision (96.57), coding level with the baseline (89.42), agentic tool calling at 74.92
- End-to-end ternary language weights across embeddings, attention projections, MLP projections, and LM head, at a true 1.72 bits per weight — no high-precision escape hatches behind a low-bit label; the vision tower ships as a separate Q8_0 mmproj pack
- 262K-token context on-device, kept practical by the Qwen3.8-27B hybrid-attention backbone (~75% linear attention)
- Two GGUF packings with custom ternary hybrid-attention kernels for llama.cpp (CUDA, Metal) — PTQ1_0 packs trits densely (1.75 bits/weight, 5.95 GB), PQ2_0 stores each trit in a 2-bit slot (2.13 bits/weight, 7.21 GB); packed weights are consumed directly, never expanded back to FP16
- ~5.9 GB 的语言模型(从 ~54 GB 的 FP16 版本缩减)——在普通笔记本电脑或单张 GPU 上即可实现完整的 27B 级别推理
- 保留 98.2% 的 FP16 智能水平:在 14 个思维模式基准测试中平均得分为 84.78 ——远高于传统 IQ2_XXS 构建版本(72.59),其占用空间约为后者的 82%,且与 UD-Q4_K_XL 仅相差 0.4 分,尽管后者占用空间是前者的三倍
- 在低于 4-bit 的传统低比特表示崩溃的区域,仍保留深度思考、推理和代理行为:数学能力与全精度相差不到半个百分点(96.57),编码能力与基线持平(89.42),代理工具调用得分为 74.92
- 端到端的三元语言权重覆盖嵌入层、注意力投影、MLP 投影和 LM 头,每个权重真正达到 1.72 位 —— 没有隐藏在低比特标签下的高精度逃生通道;视觉塔作为单独的 Q8_0 mmproj 包提供
- 设备上支持 262K token 上下文,得益于 Qwen3.8-27B 混合注意力骨干网络(~75% 线性注意力),使其保持实用性
- 两种 GGUF 打包格式,配合 llama.cpp(CUDA、Metal)的自定义三元混合注意力内核 —— PTQ1_0 密集打包三进制值(1.75 bits/weight,5.95 GB),PQ2_0 将每个三进制值存储在 2-bit 槽中(2.13 bits/weight,7.21 GB);打包后的权重被直接消耗,永远不会扩展回 FP16
更进一步:量化金融体系
看懂新闻只是起点——沿量化金融路径,把它变成能交付的工程能力