code-generation human-eval low-bit-quantization model-audit hugging-face ollama-library quantized-llms model-registries
Abstract
Developers download quantized large language models (LLMs) from public registries to run them locally. None of the registries we examined documented functional testing of their files. We tested all 305 eligible code-capable GGUF tags (the llama.cpp format) across 15 model lines in the official Ollama library, plus 22 popular Hugging Face community files. A 15-task code screen identified suspects, which we retested on all 164 HumanEval+ tasks. Seven official tags (2.3%) solved at most six of them. All were low-bit quantizations of models with at most four billion parameters. We rebuilt five suspect files from the original weights. All five registry files matched our uncalibrated rebuilds tensor for tensor, so none was corrupted. Exact reproducibility did not imply function. With the weights, toolchain and tensor mix held fixed, adding an importance matrix raised three Qwen2.5-Coder-3B builds from zero to 76-113 solved tasks. The same uncalibrated recipe left the smaller Qwen2.5-Coder-1.5B functional, showing that the recipe alone does not predict failure. None of 66 sampled tags that passed the screen was non-functional. We release the audit data and the quantcheck tool and recommend screening low-bit tags before publication, then calibrating or withholding failures.
한국어 요약
한 줄 요약
공개 모델 레지스트리에서 다운로드한 양자화된 LLM 중 1.6%는 실행 시 작동하지 않으며, 이를 감지하기 위한 툴을 제안한다.
핵심 기여도
- Ollama 라이브러리의 305개 GGUF 태그 중 7개(2.3%)가 164개 HumanEval+ 태스크 중 최대 6개만 해결함.
- Qwen2.5-Coder-3B 모델의 4개 변환본과 phi3.5-mini 변환본은 두 인퍼런스 백엔드에서 0개 태스크 해결함.
- `quantcheck` 툴과 감사 데이터셋을 공개하여 레지스트리에 기능적 검증 절차를 제안함.
- 기존 레지스트리가 백엔드 의존적 실패나 통계적으로 정상처럼 보이는 결함을 감지하지 못함.
핵심 아이디어
공개 레지스트리에서 다운로드한 양자화된 LLM 중 일부는 실행 시 기능하지 않지만, 파일 자체는 손상되지 않았다. 이는 양자화 과정에서 발생한 중요도 행렬 누락 또는 극단적 양자화로 인한 모델 콜랩스일 수 있다. 연구팀은 15개 태스크로 구성된 스모크 테스트를 통해 결함이 의심되는 모델을 선별하고, 164개 HumanEval+ 태스크로 재검증하는 프로세스를 제안한다. 이는 기존 레지스트리가 기능적 검증을 하지 않는 문제를 해결하기 위한 첫 시도이다.
기술적 접근법
- 305개 Ollama GGUF 태그와 22개 Hugging Face 커뮤니티 파일을 테스트.
- 15개 태스크로 구성된 스모크 테스트 후, 164개 HumanEval+ 태스크로 재검증.
- 두 인퍼런스 백엔드(예: Metal, CUDA)에서 동일 모델을 실행하여 백엔드 의존성 검증.
- Qwen2.5-Coder-3B 모델의 3B 버전은 중요도 행렬 추가로 76~113개 태스크 해결 가능.
- 1.5B 버전은 동일 레시피로도 정상 작동함.
주요 결과
- Ollama 라이브러리의 305개 태그 중 7개(2.3%)가 164개 HumanEval+ 태스크 중 최대 6개만 해결함.
- Qwen2.5-Coder-3B의 4개 변환본과 phi3.5-mini 변환본은 0개 태스크 해결함.
- CUDA에서 성능 저하된 커뮤니티 변환본은 Metal에서는 정상 작동함.
- 결함이 의심되는 5개 파일은 독립적으로 재구축한 결과와 텐서 단위로 일치함.
의의 및 한계
- 공개 레지스트리에서 기능하지 않는 모델이 존재함을 실증적으로 보여줌.
- `quantcheck` 툴은 모델 레지스트리에 필수적인 기능적 검증 절차로 활용 가능.
- 한계로는 모든 양자화 레벨과 모델 크기 조합을 테스트하지 못함. 또한, 일부 결함은 통계적으로 정상처럼 보임.
실용적 활용
- 개발자는 레지스트리에서 양자화 모델을 다운로드 전 `quantcheck` 툴로 검증할 수 있음.
- 모델 레지스트리는 출판 전에 기능적 검증 절차를 도입해야 함.
- 연구자와 엔지니어는 양자화 과정에서 중요도 행렬을 포함하는 절차를 강화해야 함.