Lune

ICML2025Top-tier venue

Provable Length Generalization in Sequence Prediction via Spectral Filtering

Annie Marsden, Evan Dogariu, Naman Agarwal, Xinyi Chen, Daniel Suo, Elad Hazan

Abstract

We consider the problem of length generalization in sequence prediction. We define a new metric of performance in this setting -the Asymmetric-Regret-which measures regret against a benchmark predictor with longer context length than available to the learner. We continue by studying this concept through the lens of the spectral filtering algorithm. We present a gradient-based learning algorithm that provably achieves length generalization for linear dynamical systems. We conclude with proof-of-concept experiments which are consistent with our theory.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

5 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolation cites Language Models are Few-Shot Learners
  • SpectraLDS: Provable Distillation for Linear Dynamical Systems cites Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolation
  • SpectraLDS: Provable Distillation for Linear Dynamical Systems cites Efficiently Modeling Long Sequences with Structured State Spaces
  • Efficiently Modeling Long Sequences with Structured State Spaces cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale cites Language Models are Few-Shot Learners
  • Combining Recurrent, Convolutional, and Continuous-time Models with Linear State Space Layers cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Non-Asymptotic Length Generalization cites Language Models are Few-Shot Learners
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers5

  1. Transformers Provably Learn Chain-of-Thought Reasoning with Length GeneralizationYu Huang, Zixin Wen, Aarti Singh, Yuejie Chi et al.NeurIPS 2025 · 22 citations
  2. SpectraLDS: Provable Distillation for Linear Dynamical SystemsDevan Shah, Shlomo Fortgang, Sofiia Druchyna, Elad HazanNeurIPS 2025 · 1 citation
  3. Next-Token Prediction and Regret MinimizationMehryar Mohri, Clayton Sanford, Jon Schneider, Kiran Vodrahalli et al.ICML 2026
  4. The Role of Sparsity for Length Generalization in LLMsNoah Golowich, Samy Jelassi, David Brandfonbrener, Sham M. Kakade et al.ICML 2025
  5. Non-Asymptotic Length GeneralizationThomas Chen, Tengyu Ma, Zhiyuan LiICML 2025

Builds on16

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
  2. An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
  3. Efficiently Modeling Long Sequences with Structured State SpacesAlbert Gu, Karan Goel, Christopher RéICLR 2022 · 3,482 citations
  4. Combining Recurrent, Convolutional, and Continuous-time Models with Linear State Space LayersAlbert Gu, Isys Johnson, Karan Goel, Khaled Saab et al.NeurIPS 2021 · 1,280 citations
  5. Train Short, Test Long: Attention with Linear Biases Enables Input Length ExtrapolationOfir Press, Noah A. Smith, Mike LewisICLR 2022 · 1,168 citations

Related papers

  1. Length Generalization via Auxiliary TasksPranjal Awasthi, Anupam Gupta, Ravi KumarNeurIPS 2025
  2. Alignment-Sensitive Minimax Rates for Spectral Algorithms with Learned KernelsDongming Huang, Zhifan Li, Yicheng Li, Qian LinICML 2026
  3. Universal Learning of Nonlinear DynamicsEvan Dogariu, Anand Brahmbhatt, Elad HazanICML 2026 · 5 citations
  4. Long-Short Alignment for Effective Long-Context Modeling in LLMsTianqi Du, Haotian Huang, Yifei Wang, Yisen WangICML 2025
  5. SLIP: Learning to predict in unknown dynamical systems with long-term memoryParia Rashidinejad, Jiantao Jiao, Stuart RussellNeurIPS 2020 · 16 citations
Dusk over the sea between two cliffs drawn in fine vertical lines