Auto-regressive Models

Auto-regressive models are a class of generative models that generate data sequentially, predicting the next element in a sequence based on all preceding elements. They are the foundational architecture behind most large language models (LLMs) and many time-series forecasting systems.

Core Mechanism

Key Architectures

  • Transformers: Dominant architecture for NLP, using self-attention to weigh the importance of different tokens in the context.
  • RNNs/LSTMs: Older recurrent architectures, largely superseded by Transformers due to parallelization capabilities during training.
  • Diffusion Models: Traditionally used for image generation, now being adapted for text. Unlike auto-regressive models, diffusion models denoise data iteratively and can potentially generate tokens in parallel.

Limitations

  • Latency: Sequential nature prevents parallel generation during inference, leading to slower throughput compared to non-auto-regressive methods.
  • Error Propagation: Mistakes in early tokens can compound, affecting subsequent predictions.
  • Context Window: Limited by memory constraints and attention mechanism complexity.

Recent Developments & Alternatives

References