MethodScaling up

LoRA (2021): fine-tuning with small low-rank matrices

Event date

Edward Hu and colleagues proposed low-rank adaptation, or LoRA, a way to adapt a large pretrained model to a task by training a few small added matrices while the original weights stay frozen. It made fine-tuning far cheaper in memory and storage.

Milestone 14 of 68 on the LLM history timeline, 2016 to 2026. Each dot is one milestone.

Key numbers

Reduction in trainable parameters versus Adam fine-tuning of GPT-3 175B, reported by the authors
10,000 timesarxiv.org
Reduction in GPU memory requirement, reported by the authors
3 timesarxiv.org

The cost problem

The common recipe in natural language processing was to pretrain a large model on general text and adapt it to a task. Full fine-tuning retrains every parameter, so each task needs its own complete copy of the model. The authors used GPT-3 with 175 billion parameters as the example: keeping one fine-tuned copy for every task is prohibitively expensive.

Other efficient methods existed. Adapters, for example, add small layers to the network, but they can add delay at inference time. The problem is one of storage and deployment as much as of training, because every extra copy of a 175 billion parameter model must be kept and served.

Sources: arxiv.org

How LoRA works

LoRA keeps the pretrained weights frozen. Alongside them it adds trainable low-rank decomposition matrices in each Transformer layer. In plain terms, instead of changing a large weight matrix directly, it learns a small pair of narrow matrices whose product describes the change.

Because the update is small, it can be stored separately and, unlike adapters, merged into the original weights so inference runs with no added latency. The paper also studied rank deficiency in model adaptation to explain why such small updates are enough. Only the small matrices are updated during training, so far fewer numbers need gradients and optimiser state, which is where the memory saving comes from.

Sources: arxiv.org

Reported results

Against fine-tuning GPT-3 175B with the Adam optimiser, the authors reported that LoRA cut the number of trainable parameters by 10,000 times and the GPU memory requirement by 3 times. They reported quality on par with or better than full fine-tuning on RoBERTa, DeBERTa, GPT-2 and GPT-3, with higher training throughput.

The authors released a PyTorch integration package along with implementations and checkpoints for RoBERTa, DeBERTa and GPT-2. These are the authors' own measurements on the models and tasks they chose, so results on other models may differ. The method is widely used today for adapting open weights models on modest hardware.

Sources: arxiv.org

Why it mattered

  • It made it practical to customise a very large model on limited hardware, since only the small matrices are trained.
  • Adaptations are small files, so many task versions can share one base model.
  • It sits alongside instruction tuning and RLHF as one of the post-training tools described later on this timeline.

Questions

What does LoRA stand for?
LoRA stands for low-rank adaptation. It was introduced in a June 2021 paper by researchers at Microsoft.
Does LoRA add latency at inference time?
The authors state that, unlike adapter methods, it adds no inference latency, because the small matrices can be merged into the frozen weights.
Why is LoRA cheaper than full fine-tuning?
Only the small added matrices are trained, so far fewer parameters need gradients and optimiser state. The authors reported 10,000 times fewer trainable parameters and 3 times less GPU memory for GPT-3 175B.
Does LoRA change the original model weights?
During training the original weights are frozen. Only the added low-rank matrices are trained.

About this page

Part of our LLM history timeline. The event happened on 17 June 2021; we wrote this page on 20 November 2026 from the original papers and announcements listed below. Lab-reported results are labelled as such. Read our editorial policy. Found an error? Tell us and we will correct it with a dated note.

On the timeline

Related milestones

Terms and labs

Sources

Papers and announcements we read for this page.

  1. Hu et al., LoRA: Low-Rank Adaptation of Large Language Models (arXiv)

Sign in to vote as verified

Signed-in votes count once per account and show as verified. You can still vote without an account.

We use your email only to run your account. No marketing, no sharing, no passwords. Delete your account any time. Privacy

Delete your account?

This removes your account, your email and every vote you made while signed in. It cannot be undone.