Training vs inference: same forward pass, one extra step

Inference runs the forward pass with frozen weights. Training adds a backward pass that nudges the weights to reduce the error. Run steps on "the cat sat on the → mat" and watch the loss fall — then switch to inference to see the weights freeze.

Forward
predict next word
Loss
compare to target
Backward
nudge weights
loss per step (lower is better)