passdrill
AI & LLM Engineering · How LLMs Work: Transformers & Training · Card 018/024 easy

Decoder-only language models such as GPT are pretrained on a simple self-supervised objective before any instruction tuning or reinforcement learning stage is applied. What is that pretraining objective?

  1. Predicting whether two randomly paired sentences from the corpus originally appeared next to each other in the source text, using a binary classification loss
  2. Reconstructing a small number of randomly masked-out tokens scattered throughout an otherwise-visible input sequence, using a masked-token classification loss
  3. Predicting the next token in a sequence given only the tokens that came before it, using a cross-entropy loss between the model's predicted probability distribution and the actual next token, repeated across every position in the training corpus
  4. Predicting a scalar reward score for an entire generated sequence, using a regression loss trained on human preference comparisons
Next card → Shuffle