arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2601.14277cs.LG
收藏

我应该使用哪种量化?对llama.cpp量化在Llama-3.1-8B-Instruct上的统一评估

Which Quantization Should I Use? A Unified Evaluation of llama.cpp Quantization on Llama-3.1-8B-Instruct

Uygar Kurt

AI总结:

本文评估了llama.cpp不同量化方案在Llama-3.1-8B-Instruct模型上的性能,为选择合适的量化方法提供指导。

摘要:

量化是一种实用技术,用于通过减少存储和操作模型权重时使用的精度来使大型语言模型更容易部署。这可以降低内存使用并提高在受限制硬件上的运行可行性,这对于在本地运行模型的用户尤其相关。llama.cpp中的量化使大型语言模型能够在通用硬件上运行,但可用的格式往往评估不一致,使在不同方案之间做出选择变得困难。我们对llama.cpp量化在单一现代模型Llama-3.1-8B-Instruct(FP16,GGUF)上的统一实证研究涵盖了3-8位K-量化和遗留格式。我们评估了下游任务性能,包括标准推理、知识、指令遵循和真实性基准,并测量了困惑度和CPU吞吐量(预填充/解码)以及模型大小、压缩和量化时间。最终,这项工作是选择llama.cpp量化方案的实用指南,帮助读者为他们的预期用途和资源预算做出有意识、情境化的决策。

英文摘要:

Quantization is a practical technique for making large language models easier to deploy by reducing the precision used to store and operate on model weights. This can lower memory use and improve runtime feasibility on constrained hardware, which is especially relevant for users running models locally. Quantization in llama.cpp enables large language models to run on commodity hardware, but available formats are often evaluated inconsistently, making it hard to choose among schemes. We present a unified empirical study of the llama.cpp quantization on a single modern model, Llama-3.1-8B-Instruct (FP16, GGUF), covering 3-8 bit K-quant and legacy formats. We evaluate downstream task performance across standard reasoning, knowledge, instruction-following, and truthfulness benchmarks, and also measure perplexity and CPU throughput (prefill/decoding) alongside model size, compression, and quantization time. Ultimately, this work is a practical guide for choosing a llama.cpp quantization scheme, helping readers make informed, context-aware decisions for their intended use and resource budget.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑