Intermediate level · Module 1: Understanding LLM Architecture and Capabilities · Lesson 2 of 3
How LLMs Are Trained and Aligned
Learners distinguish pre-training on large text, supervised instruction tuning, and preference-based tuning (RLHF, DPO), and see how each shapes behaviour.
In this lesson you will
- Describe the training stages of an assistant LLM
- Explain why aligned models refuse or hedge
Key concepts
pre-traininginstruction tuning (SFT)preference tuning (RLHF, DPO)alignmentknowledge cut-off
The lesson
Pre-training teaches a model to predict text from a huge corpus; it learns language and broad knowledge. Supervised fine-tuning on instruction-response examples teaches it to follow instructions.
Preference tuning, using human feedback (RLHF) or methods such as Direct Preference Optimization (DPO), teaches it to prefer helpful, harmless answers. This is why assistants refuse some requests and hedge on uncertain ones.
Knowledge stops at the training cut-off, and alignment does not make facts reliable. Applications must still ground answers and verify them.
Step by step
- Compare a base model and its instruct version on the same prompt.
- Note differences in following instructions.
- Read the abstract of the instruction-following paper.
- Summarise the three training stages.
Practice activity
Compare base and instruct models and write a short explanation of the training stages.
Expected result: Observed differences linked correctly to training stages.
Check your understanding
-
What does instruction tuning teach a model?
Show answer
To follow instructions using examples of instructions and responses.
-
Does alignment make an LLM's facts reliable?
Show answer
No. Facts still need grounding and verification.
Further learning
Taught live by an instructor — online or in person. Free course lessons are for self-study and do not lead to a certificate — see registration options.