Advanced · module A8
Large Language Models: Training, Adaptation and Evaluation
By the end: Explain each stage of an LLM's life, fine-tune an open model efficiently, and evaluate LLM systems rigorously
- Covers
- How LLMs are pre-trained, aligned, adapted, served and evaluated
- Contents
- 4 chapters, 15 topics
- Time
- About 4 hours
- Level
- Advanced
- Your progress
- 0 / 15
This module builds on Sequence Models, Transformers and Modern NLP. We suggest looking at it first, but the choice is yours.
Chapter 1 Pre-Training
- 1.115 minBeing written
Pre-Training Data and Objectives
Web-scale data, cleaning, deduplication and next-token prediction
Lab: build a small data pipeline
- 1.212 minBeing written
Scaling Laws and Compute
How performance grows with data, parameters and compute
Interactive: scaling-law curves
- 1.330 minBeing written
Training a Small Language Model
Training a tiny GPT end to end
Code: train a character-level GPT
Chapter 2 Post-Training and Alignment
- 2.115 minBeing written
Instruction Tuning
Supervised fine-tuning on instructions and conversations
Code: instruction-tune a small model
- 2.215 minBeing written
Learning from Human Feedback
RLHF, reward models, DPO and constitutional approaches
Interactive: the preference pipeline
- 2.312 minBeing written
Reasoning Models
Chain of thought, test-time compute and reinforcement learning for reasoning
Lab: compare reasoning strategies
Chapter 3 Adapting LLMs
- 3.110 minBeing written
Choosing an Approach
Prompting, retrieval, fine-tuning or training from scratch
Decision exercise
- 3.220 minBeing written
Parameter-Efficient Fine-Tuning
LoRA, QLoRA and adapters
Code: LoRA fine-tuning
W′ = W + BA
- 3.312 minBeing written
Quantisation and Distillation
Making models smaller and faster
Code: quantise and compare
Chapter 4 Serving and Evaluating
- 4.115 minBeing written
Inference and Serving
KV cache, batching, speculative decoding and serving engines
Lab: serve an open model
- 4.210 minBeing written
Long Context and Memory
Context windows and strategies for long documents
Lab: long-document question answering
- 4.315 minBeing written
Evaluating LLMs
Benchmarks, contamination, LLM-as-judge and human evaluation
Code: build an evaluation suite
- 4.412 minBeing written
Multimodal LLMs
Models that read images, audio and text together
Lab: a document question-answering demo
- 4.58 minBeing written
Open and Closed Models
Licences, trade-offs, cost and model selection
Comparison exercise
- 4.620 minBeing written
Module Review and Assessment
Coding tasks and a scored quiz
Graded project