Pretraining, supervised fine-tuning and parameter-efficient adaptation
What it is
Pretraining learns broad statistical structure from large, diverse corpora using a self-supervised objective such as next-token prediction. Fine-tuning then adapts that base model with curated labelled examples, instructions, or preference data so its outputs suit a narrower task or behaviour target. Parameter-efficient methods such as LoRA add small trainable low-rank updates while keeping most base weights frozen, reducing memory and making several adaptations practical to store. The data format, prompt template, target construction, and split policy are all part of the fine-tuning method—not preprocessing footnotes.
Why it matters
This division explains how capable models can be adapted without reproducing their original compute budget, and why data quality often matters more than a larger fine-tuning run. Fine-tuning can improve a task, but it can also cause catastrophic forgetting, narrow a model's style, or teach benchmark leakage; compare against the untouched base model on held-out and representative evaluations.
In the real world: Taking a general model and adapting it to write in a company's support style.
Visual example
Deep learningBroad pretraining creates a base model; narrower data changes its behaviour for a specific use.
import torch
checkpoint = torch.load('base_model.pt', map_location='cpu')
model.load_state_dict(checkpoint['state_dict'])
# Fine-tuning uses a much smaller learning rate than pretraining did.
optimizer = torch.optim.AdamW(model.parameters(), lr=2e-5, weight_decay=0.01)Mixing evaluation examples into fine-tuning data. A polished benchmark score then measures memorisation, not task generalisation.