Deep LearningSequence-to-Sequence Training

What is exposure bias in sequence-to-sequence neural networks?

**Exposure bias is the training–inference mismatch that can arise in an autoregressive sequence-to-sequence (seq2seq) model when it learns to predict the next token from *correct previous tokens* during training, but must use *its own earlier predictions* at inference time.** If an early prediction is wrong, later predictions may receive an unfamiliar or misleading prefix, making recovery harder.

Where does the mismatch come from?

  • During teacher-forced training: The decoder predicts the next target token while conditioning on the *reference (ground-truth) prefix*, even if its own previous prediction was wrong.
  • During autoregressive inference: The correct target is unavailable. The decoder must feed its *generated prefix* back into subsequent predictions; that prefix may already contain mistakes.

The decoder therefore practices mostly on reference-token histories but is evaluated on histories it generates itself. The dedicated “What is teacher forcing in neural networks?” article explains the training technique; the issue here is what changes when the model runs without the teacher.

Beginner-friendly example: one mistake changes what comes next

Imagine a translation model whose correct English target is “I love tea”.

Teacher-forced training

  1. Given <start>, predict I.
  2. Given the correct prefix I, predict love.
  3. Given the correct prefix I love, predict tea.

Even if the model accidentally predicts “like” at step 2, step 3 is still trained using the correct word “love”.

Autoregressive inference

  1. Given <start>, the model generates I.
  2. Given I, it mistakenly generates `like`.
  3. It now sees `I like` (not I love) and might generate `coffee`, producing “I like coffee” rather than “I love tea”.

For a toy numerical illustration, suppose the model assigns 85% probability to tea after the *correct* prefix I love, but only 10% after the *generated* prefix I like. The numbers are hypothetical: they show how a changed prefix can change the next-token distribution, not a guaranteed outcome.

Why does exposure bias matter?

  • Errors may compound: A mistaken token changes the context for the next step; another mistake can then change the following context.
  • Training metrics can look better than generated sequences: A low teacher-forced next-token loss does not ensure reliable complete-sequence generation.
  • Longer outputs offer more opportunities for drift: For translation, summarization, or other multi-step generation, the model may gradually move away from the intended sequence.

Important nuance: Exposure bias is a *potential source* of sequence-generation errors, not proof that every mistake will cascade or that every autoregressive model must fail. Models can sometimes recover, and the extent to which this mismatch hurts generation depends on generalization and the task.

How should it be assessed?

Alongside teacher-forced token-level evaluation, run the decoder autoregressively on held-out inputs, inspect full generated sequences, and check whether it can recover after an incorrect token. Techniques that change training-time exposure to generated prefixes are studied separately; the next question covers scheduled sampling.

Key takeaway: Teacher forcing trains on correct history; inference runs on the model's own history. Exposure bias is the gap between those conditions and the risk of error accumulation.

Research: Schmidt (2019), *Generalization in Generation: A closer look at Exposure Bias* and Nicolai & Silfverberg (2020), *Noise Isn’t Always Negative: Countering Exposure Bias in Sequence-to-Sequence Inflection Models*.

Sources & Research References

#what is exposure bias in seq2seq models#exposure bias teacher forcing versus inference#exposure bias in sequence-to-sequence neural networks#autoregressive decoding error accumulation#teacher forcing training inference mismatch#exposure bias seq2seq example#why exposure bias matters for sequence generation#deep-learning#exposure-bias#sequence-to-sequence

Learning Sequence

Deep Learning Curriculum

84% Completed
Up NextDeep Learning

What is scheduled sampling in sequence model training?

Explore Related Questions

Deepen your understanding across related Deep Learning topics.

Machinoai Logo
Machinoai

Your edge in the AI era. Deep dives into machine learning concepts, paper explainers, verified industry jobs, and developer tools.

© 2026 Machinoai. All rights reserved.