Read the loss curve before you trust the model.
Training loss is the average error on the examples the model is learning from; validation loss is the same measure on examples it has not seen. Training loss falling while validation loss rises is overfitting. Catastrophic forgetting is the model losing general abilities while learning your task. Both show up in the curves and in held-out tests before they show up with users.
- Training loss
- Error on the training set, per step
- Validation loss
- Error on held-out data; the one that matters
- Overfitting
- Training falls, validation rises
- Forgetting
- Task improves, general skills degrade
- 5production AI apps
- 14engineers led
- 200+students mentored
Questions students ask
The training loss questions searched most, answered from watching many fine-tunes.
What is training loss?
Training loss is a single number that says how far the model's predictions are from the targets on the batch of examples it just saw. For language models it is the cross-entropy between the model's predicted probability of each next token and the actual next token, averaged over the tokens in the batch. Lower means the model assigns higher probability to the right tokens. Training adjusts the weights to push this number down. It is reported every step or every few steps and plotted as a curve, which is the first thing to look at during and after a run.
What is training loss and validation loss?
Training loss is computed on the examples the model is being updated on, so it reflects how well the model has memorised or learned them. Validation loss is computed, without updating the weights, on a held-out set the model never trains on, so it reflects how well what it learned generalises to new examples from the same distribution. Early in training both fall together. The moment validation stops falling while training continues to fall, further training is teaching the model your specific examples rather than your task. Validation loss is the number that predicts behaviour on real inputs.
How is training loss calculated?
For each token position in each example, the model outputs a probability distribution over the vocabulary; the loss at that position is the negative log of the probability it gave to the actual token. Those values are averaged over all target tokens in the batch (in instruction tuning, usually only over the response tokens, with the prompt tokens masked out so the model is not trained to predict the question). The result is the batch loss. A loss of 2.0 means the model gave the true token a probability of about 0.135 on average; a loss of 0.5 means about 0.61. Perplexity is the exponential of the loss, the same information on a different scale.
What is good training loss?
There is no universal good value; it depends on the task, the data and the tokenizer. Fine-tuning a chat model on a consistent task often lands around 0.5 to 1.5 on the response tokens; a highly predictable format can go lower, open-ended writing stays higher. What matters is the shape: training loss should fall steadily and then flatten, validation loss should track it closely and flatten at a similar value. A training loss near zero with validation much higher is a memorised dataset. Compare runs against each other on the same validation set, not against a number from a blog post.
Why is training loss increasing?
- Learning rate too high: the updates overshoot; loss spikes or climbs. Lower it or add warm-up.
- Bad batches: corrupted or inconsistent examples, or a shuffle that groups unusual data; inspect the examples at the spike.
- Numerical issues: mixed-precision overflow producing NaN or inf; use bfloat16 or gradient scaling and clip gradients.
- Learning-rate schedule restarts, which cause expected bumps.
- Too-small batches with noisy gradients; increase the effective batch with gradient accumulation.
- A genuine bug: labels misaligned with inputs, the chat template applied wrongly, or prompt tokens not masked.
What is training loss curve?
The curve is training loss plotted against steps or epochs, usually with validation loss on the same axes. A healthy curve drops quickly at first, then more slowly, then flattens; validation follows the same path slightly above. A curve that keeps dropping in a straight line after the validation curve has flattened is heading into overfitting. Sudden spikes point to the learning rate or bad data. A curve that never drops means the learning rate is too low, the adapters are not attached to the right layers, or the data is not what you think. Plot it every time; it is the cheapest diagnostic you have.
How many epochs to fine tune LLM
One to three. With LoRA on a few hundred to a few thousand examples, most of the gain arrives in the first epoch; a second often helps; a third sometimes helps and sometimes starts overfitting; beyond that the model memorises. Decide by the validation curve, not by a fixed number: stop when validation loss has flattened, and keep the checkpoint with the lowest validation loss. Larger datasets need fewer epochs; tiny datasets may need more but will overfit faster, which is a sign to collect data rather than train longer. Learning rate and epochs interact; a smaller learning rate tolerates more epochs.
What is overfitting in LLMs?
Overfitting is the model learning the training examples themselves, their exact phrasings and quirks, instead of the pattern that generated them. The symptom is excellent performance on training data and poor performance on new inputs: validation loss rises, outputs on fresh prompts copy training responses word for word, the model becomes rigid or repetitive. It is most likely with small datasets, many epochs, high learning rates and large adapter ranks. In FineTune Studio the base-versus-tuned comparison on held-out prompts exists to catch it: a tuned model that is worse on new inputs than the base model has overfit.
How to deal with overfitting
- Hold out a validation set before training and watch its loss; stop at the minimum.
- Collect more and more varied examples; this is the only fix that addresses the cause.
- Train fewer epochs with a smaller learning rate.
- Lower the LoRA rank or add dropout to the adapters; regularise.
- Deduplicate and diversify the data; near-duplicate examples are memorised fastest.
- Evaluate on held-out prompts with a task-appropriate score, and compare with the base model before shipping.
What is catastrophic forgetting in LLM?
Catastrophic forgetting is the model losing abilities it had before fine-tuning, such as general knowledge, instruction following, reasoning or other languages, because training on a narrow dataset overwrote the weights that supported them. The fine-tuned model does your task well and has become worse at everything else. It is distinct from overfitting, though they often appear together. LoRA reduces it because the base weights stay frozen and the adapter can only make small structured changes, which is one reason PEFT is the default. Mixing a slice of general instruction data into your dataset and keeping epochs low reduce it further. Test for it by running general prompts on the tuned model and comparing with the base.
Read a run in five minutes
What to check before believing a fine-tune.
- 01
Plot both curves
Training and validation on one chart. Flattening together is good; diverging is overfitting.
- 02
Pick the checkpoint
The one at the validation minimum, not the last one.
- 03
Held-out task score
Score the tuned model and the base model on the same unseen prompts.
- 04
General prompts
Ten unrelated prompts on both models. If the tuned one got worse, you have forgetting.
In the room
Where these systems get explained to students.


Read next
The run itself and the data behind it.
A fine-tune that looks good but isn't?
I read the curves and run the held-out comparison before anything ships. Send me the run.

