BitNet a4.8 : Activations sur 4 bits pour les LLM sur 1 bit
BitNet a4.8: 4-bit Activations for 1-bit LLMs
November 7, 2024
papers.authors: Hongyu Wang, Shuming Ma, Furu Wei
cs.AI
papers.abstract
Les recherches récentes sur les modèles de langage à grande échelle (LLM) 1-bit, tels que BitNet b1.58, ouvrent une voie prometteuse pour réduire les coûts d'inférence des LLM tout en maintenant leurs performances. Dans ce travail, nous présentons BitNet a4.8, permettant des activations 4-bit pour les LLM 1-bit. BitNet a4.8 utilise une stratégie hybride de quantification et de sparsification pour atténuer les erreurs de quantification introduites par les canaux aberrants. Plus précisément, nous utilisons des activations 4-bit pour les entrées des couches d'attention et du réseau feed-forward, tout en sparsifiant les états intermédiaires suivis d'une quantification 8-bit. Des expériences approfondies montrent que BitNet a4.8 atteint des performances comparables à BitNet b1.58 avec des coûts d'entraînement équivalents, tout en étant plus rapide en inférence grâce à l'activation de noyaux 4-bit (INT4/FP4). De plus, BitNet a4.8 active seulement 55 % des paramètres et prend en charge un cache KV 3-bit, améliorant ainsi l'efficacité du déploiement et de l'inférence des LLM à grande échelle.
English
Recent research on the 1-bit Large Language Models (LLMs), such as BitNet
b1.58, presents a promising direction for reducing the inference cost of LLMs
while maintaining their performance. In this work, we introduce BitNet a4.8,
enabling 4-bit activations for 1-bit LLMs. BitNet a4.8 employs a hybrid
quantization and sparsification strategy to mitigate the quantization errors
introduced by the outlier channels. Specifically, we utilize 4-bit activations
for inputs to the attention and feed-forward network layers, while sparsifying
intermediate states followed with 8-bit quantization. Extensive experiments
demonstrate that BitNet a4.8 achieves performance comparable to BitNet b1.58
with equivalent training costs, while being faster in inference with enabling
4-bit (INT4/FP4) kernels. Additionally, BitNet a4.8 activates only 55% of
parameters and supports 3-bit KV cache, further enhancing the efficiency of
large-scale LLM deployment and inference.