The Open Model EcosystemLesson 52 of 71

Module 6 · Adapting a model to your work

What a LoRA actually is

In this lesson

  • 9 min read
  • 6 reading sections
  • Knowledge check
  • Lesson 2 of 11 in this chapter

This chapter’s goalDecide with evidence whether a task needs fine-tuning at all; if it does, build the dataset, size a LoRA to fit free hardware, run it, and demonstrate on a held-out set and a regression suite that the adapted model is better at the task and no worse at everything else.

This chapter’s media

The film explains chapter ideas. The audiobook narrates the complete teaching text.

FormatEnglishहिंदी
Chapter filmNot availableNot available
Full audiobookNot availableNot available
The same tune, two budgetsFull fine-tuning an 8BEvery weight updatedGradients and optimiser state for 8 billionAround 110 GB of training memoryA 16 GB copy of the model per variantSeveral datacentre GPUsLoRA at rank 16, all linear layersBase frozen, and B starts at zeroAbout 40 million trainable, half a per centFits on a free notebook GPUA 40 to 200 MB adapter per variantKeep fifty of themOne 4096 by 4096 projection is 16.8 million parameters fully tuned, or 131,072 at rank 16. Print thetrainable percentage on every run: if it is far from what you expected, the target modules are wrongand the next three hours will produce nothing.
One 4096 by 4096 projection is 16.8 million parameters fully tuned, or 131,072 at rank 16. Print the trainable percentage on every run: if it is far from what you expected, the target modules are wrong and the next three hours will produce nothing.

Figure

A little at a time

Explore an idea, try it, then check what stays.

Step 1 of 7Free · no account needed
Lesson steps

The trick, in one equation

Full fine-tuning updates every weight matrix W by some ΔW of the same shape. LoRA observes that the useful part of ΔW is empirically low-rank, and represents it as a product of two thin matrices:

Text
W' = W + (alpha / r) * B @ A

W : d x k   (frozen, never updated)
B : d x r   (initialised to zeros)
A : r x k   (initialised randomly)
r : the rank, typically 8 to 64

The base weights never move. Only A and B are trained. Because B starts at zero, the model begins identical to the base and departs from it gradually, which is why LoRA training is stable.

Your place and first choices stay on this browser. Classroom credit is recorded separately.

Every lesson here is open. Your progress is recorded once you pass the Maths You Actually Need exam.

Stuck on something?Ask Anjali, your AI tutor

How to cite: Addaly (2026) ‘What a LoRA actually is’, in The Open Model Ecosystem. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/open-models/lora-mechanics (Accessed: 29 November 2026).