Fine-Tuning & Model Customization
Teach an LLM new skills, knowledge, and behavior — from 'what is a model?' to LoRA, QLoRA, synthetic data, preference tuning, evaluation, and shipping a fine-tuned model like a pro.
Fine-Tuning & Model Customization: From Zero to Mastery
Welcome. This is a complete, self-contained course on teaching large language models (LLMs) new skills, knowledge, and behavior. You will start knowing nothing about how models are trained and finish able to design, run, evaluate, and ship a fine-tuned model like a professional.
The tone throughout is deliberately plain. No concept is skipped or hand-waved — but every concept is explained in everyday language first, then made precise. If a term sounds intimidating, that is a failure of the explanation, not of you.
Who this is for
- You are new to AI but technically curious. You can read a little Python, or are willing to.
- You want to become an industry expert — someone a company would pay to customize models — not just someone who can copy-paste a notebook.
- You learn best when ideas build on each other, with the why always explained before the how.
You do not need a math degree. Where math appears, it is introduced gently and always tied back to intuition. You do not need a GPU to read the course; for the hands-on parts we use free and low-cost options (Google Colab, small models).
What you will be able to do at the end
- Explain how an LLM is built and why fine-tuning works, in your own words.
- Decide correctly between prompting, RAG, and fine-tuning for a real problem.
- Build and clean a training dataset, including generating synthetic data safely.
- Run Supervised Fine-Tuning (SFT) end to end.
- Use PEFT methods — especially LoRA and QLoRA — to fine-tune large models on modest hardware.
- Align a model to preferences with DPO and understand RLHF.
- Evaluate a model rigorously so you know whether you actually improved it.
- Merge, quantize, deploy, and serve your model in production.
- Diagnose and fix the things that go wrong — the skills that separate experts from beginners.
How the course is organized
The course is split into modules, each in its own file inside the modules/ folder. They are designed to be read in order the first time, because each one assumes the vocabulary of the ones before it. After your first pass, each module also works as a standalone reference.
| # | Module | What it gives you |
|---|---|---|
| 00 | Orientation & Setup | How to study this, prerequisites, tools, and the big-picture map |
| 01 | What Is a Language Model? | Tokens, embeddings, transformers, and pretraining — the foundation |
| 02 | Why Fine-Tune? Prompting vs RAG vs Fine-Tuning | The single most important decision in the field |
| 03 | Training Fundamentals | Loss, gradients, learning rate, epochs, overfitting — how learning happens |
| 04 | Data Foundations | Datasets, formats, chat templates, tokenization, masking |
| 05 | Supervised Fine-Tuning (SFT) | The core technique, top to bottom |
| 06 | PEFT: Parameter-Efficient Fine-Tuning | The family of cheap, fast fine-tuning methods |
| 07 | LoRA In Depth | The most important PEFT method, with the math made simple |
| 08 | QLoRA & Quantization | Fine-tuning huge models on a single GPU |
| 09 | Synthetic Data Generation | Creating training data when you don’t have any |
| 10 | Data Quality & Curation | Why “garbage in, garbage out” decides everything |
| 11 | Evaluation | Proving your model is actually better |
| 12 | Preference Tuning: RLHF, DPO & friends | Teaching taste, not just facts |
| 13 | Hands-On End-to-End Project | Build a real fine-tuned assistant, start to finish |
| 14 | Deployment & Serving | Merging, packaging, and running your model in production |
| 15 | Advanced Topics & Mastery | Long context, multi-adapter serving, MoE, troubleshooting, and the road ahead |
A separate Glossary defines every technical term used anywhere in the course. Whenever you hit a word you don’t recognize, look there first.
How to study this (read this once)
- Don’t rush the early modules. Modules 01–04 contain no fine-tuning at all, and beginners are tempted to skip them. Don’t. Almost every expensive mistake in fine-tuning is really a misunderstanding from these foundations.
- Type the code yourself. Reading code creates the illusion of understanding. Typing it (and fixing your typos) creates the real thing.
- Keep a “confusion log.” When something doesn’t click, write the question down and keep going. Most confusions resolve themselves one or two modules later. The ones that don’t are exactly what to ask a mentor or search for.
- Build one project all the way through. Pick a small, real task you care about (a support-reply assistant, a SQL generator, a style-matching writer) and carry it across the hands-on modules. A finished project teaches more than ten tutorials.
A note on the field moving fast
Specific library versions, model names, and price points change every few months. This course is built so that the concepts — the parts that don’t change — carry the weight, and the tools are treated as interchangeable examples. When you learn why LoRA works, you can pick up next year’s library in an afternoon. That durability is the whole point.
Now open Module 00 and let’s begin.