QLoRA: Efficient Finetuning of Quantized LLMs

Authors: Tim Dettmers, Artidoro Pagnoni, Ari Holtzman, Luke Zettlemoyer

Extended NeurIPS submission
License: CC BY 4.0
AI-generated keywords: QLoRA Finetuning 4-bit NormalFloat (NF4) Paged Optimizers Vicuna Benchmark

AI-generated Key Points

  • QLoRA is an efficient finetuning approach that enables the finetuning of a 65B parameter model on a single 48GB GPU while preserving full 16-bit finetuning task performance
  • Gradients are backpropagated through a frozen, 4-bit quantized pretrained language model into Low Rank Adapters (LoRA)
  • Innovations to save memory without sacrificing performance include the use of 4-bit NormalFloat (NF4), double quantization, and paged optimizers
  • QLoRA was used to finetune more than 1,000 models and provide a detailed analysis of instruction following and chatbot performance across eight instruction datasets, multiple model types (LLaMA, T5), and model scales that would be infeasible to run with regular finetuning
  • Results show that QLoRA finetuning on a small high-quality dataset leads to state-of-the-art results even when using smaller models than the previous state-of-the-art
  • Qualitative analysis shows that their best model family named Guanaco outperforms all previously released models on the Vicuna benchmark reaching 99.3% of ChatGPT's performance level while only requiring 24 hours of finetuning on a single GPU
  • They also provide a detailed analysis of chatbot performance based on both human and GPT-4 evaluations showing that GPT-4 evaluations are a cheap and reasonable alternative to human evaluation
  • The authors release all their models and code including CUDA kernels for 4-bit training which will enable further exploration in this area
Also access our AI generated: Comprehensive summary, Lay summary, Blog-like article; or ask questions about this paper to our AI assistant.

Abstract: We present QLoRA, an efficient finetuning approach that reduces memory usage enough to finetune a 65B parameter model on a single 48GB GPU while preserving full 16-bit finetuning task performance. QLoRA backpropagates gradients through a frozen, 4-bit quantized pretrained language model into Low Rank Adapters~(LoRA). Our best model family, which we name Guanaco, outperforms all previous openly released models on the Vicuna benchmark, reaching 99.3% of the performance level of ChatGPT while only requiring 24 hours of finetuning on a single GPU. QLoRA introduces a number of innovations to save memory without sacrificing performance: (a) 4-bit NormalFloat (NF4), a new data type that is information theoretically optimal for normally distributed weights (b) double quantization to reduce the average memory footprint by quantizing the quantization constants, and (c) paged optimziers to manage memory spikes. We use QLoRA to finetune more than 1,000 models, providing a detailed analysis of instruction following and chatbot performance across 8 instruction datasets, multiple model types (LLaMA, T5), and model scales that would be infeasible to run with regular finetuning (e.g. 33B and 65B parameter models). Our results show that QLoRA finetuning on a small high-quality dataset leads to state-of-the-art results, even when using smaller models than the previous SoTA. We provide a detailed analysis of chatbot performance based on both human and GPT-4 evaluations showing that GPT-4 evaluations are a cheap and reasonable alternative to human evaluation. Furthermore, we find that current chatbot benchmarks are not trustworthy to accurately evaluate the performance levels of chatbots. A lemon-picked analysis demonstrates where Guanaco fails compared to ChatGPT. We release all of our models and code, including CUDA kernels for 4-bit training.

Submitted to arXiv on 23 May. 2023

Ask questions about this paper to our AI assistant

You can also chat with multiple papers at once here.

AI assistant instructions?

Results of the summarizing process for the arXiv paper: 2305.14314v1

  • Comprehensive Summary
  • Key points
  • Layman's Summary
  • Blog article
The paper presents QLoRA, an efficient finetuning approach that enables the finetuning of a 65B parameter model on a single 48GB GPU while preserving full 16-bit finetuning task performance. The authors achieve this by backpropagating gradients through a frozen, 4-bit quantized pretrained language model into Low Rank Adapters (LoRA). They introduce several innovations to save memory without sacrificing performance, including the use of 4-bit NormalFloat (NF4), a new data type that is information theoretically optimal for normally distributed weights, double quantization to reduce the average memory footprint by quantizing the quantization constants, and paged optimizers to manage memory spikes. The authors use QLoRA to finetune more than 1,000 models and provide a detailed analysis of instruction following and chatbot performance across eight instruction datasets, multiple model types (LLaMA, T5), and model scales that would be infeasible to run with regular finetuning (e.g., 33B and 65B parameter models). Their results show that QLoRA finetuning on a small high-quality dataset leads to state-of-the-art results even when using smaller models than the previous state-of-the-art. In addition to quantitative analysis, the authors perform qualitative analysis in two sections. First, they analyze Elo ratings for a tournament between models where models compete to generate the best response for a prompt judged by human raters or GPT-4. Overall, their best model family named Guanaco outperforms all previously released models on the Vicuna benchmark reaching 99.3% of ChatGPT's performance level while only requiring 24 hours of finetuning on a single GPU. Second, they provide a detailed analysis of chatbot performance based on both human and GPT-4 evaluations showing that GPT-4 evaluations are a cheap and reasonable alternative to human evaluation. They also find that current chatbot benchmarks are not trustworthy to accurately evaluate the performance levels of chatbots. The authors acknowledge some limitations of their work including the lack of analysis on non-English languages and the need for more research on how to improve the quality of instruction following models. Overall their approach presents a promising direction for efficient finetuning of large language models while maintaining high performance. The authors release all their models and code including CUDA kernels for 4-bit training which will enable further exploration in this area.

Assess the quality of the AI-generated content by voting

Score: -2

Why do we need votes?

Votes are used to determine whether we need to re-run our summarizing tools. If the count reaches -10, our tools can be restarted.

The previous summary was created more than a year ago and can be re-run (if necessary) by clicking on the Run button below.

Similar papers summarized with our AI tools

Navigate through even more similar papers through a

tree representation

Disclaimer: The AI-based summarization tool and virtual assistant provided on this website may not always provide accurate and complete summaries or responses. We encourage you to carefully review and evaluate the generated content to ensure its quality and relevance to your needs.