Lune

EMNLP2025Top-tier venue

A Training-Free Length Extrapolation Approach for LLMs: Greedy Attention Logit Interpolation

Yan Li, Tianyi Zhang, Zechuan Li, Caren Han

Abstract

Transformer-based Large Language Models (LLMs) struggle with inputs exceeding their training context window due to positional outof-distribution (O.O.D.) issues that disrupt attention. Existing solutions, including finetuning and training-free methods, face challenges like inefficiency, redundant interpolation, logit outliers, or loss of local positional information. We propose Greedy Attention Logit Interpolation (GALI), a training-free method that improves length extrapolation by greedily reusing pretrained positional intervals and interpolating attention logit to eliminate outliers. GALI achieves stable and superior performance across a wide range of long-context tasks without requiring input-length-specific tuning. Our analysis further reveals that LLMs interpret positional intervals unevenly and that restricting interpolation to narrower ranges improves performance, even on short-context tasks. GALI represents a step toward more robust and generalizable long-text processing in LLMs. Our implementation of GALI, along with the experiments from our paper, is open-sourced at https://github.com/adlnlp/Gali .

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.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Efficient Streaming Language Models with Attention Sinks cites YaRN: Efficient Context Window Extension of Large Language Models
  • Efficient Streaming Language Models with Attention Sinks cites Compressive Transformers for Long-Range Sequence Modelling
  • YaRN: Efficient Context Window Extension of Large Language Models cites Compressive Transformers for Long-Range Sequence Modelling
  • LongRoPE: Extending LLM Context Window Beyond 2 Million Tokens cites Efficient Streaming Language Models with Attention Sinks
  • LongRoPE: Extending LLM Context Window Beyond 2 Million Tokens cites YaRN: Efficient Context Window Extension of Large Language Models
  • LongRoPE: Extending LLM Context Window Beyond 2 Million Tokens cites Compressive Transformers for Long-Range Sequence Modelling
  • LongLoRA: Efficient Fine-tuning of Long-Context Large Language Models cites YaRN: Efficient Context Window Extension of Large Language Models
  • LongLoRA: Efficient Fine-tuning of Long-Context Large Language Models cites Compressive Transformers for Long-Range Sequence Modelling
Builds onCited byLeft to right by year; the more cited, the higher.

Builds on11

  1. Efficient Streaming Language Models with Attention SinksGuangxuan Xiao, Yuandong Tian, Beidi Chen, Song Han et al.ICLR 2024 · 1,714 citations
  2. Compressive Transformers for Long-Range Sequence ModellingJack W. Rae, Anna Potapenko, Siddhant M. Jayakumar, Chloe Hillier et al.ICLR 2020 · 833 citations
  3. YaRN: Efficient Context Window Extension of Large Language ModelsBowen Peng, Jeffrey Quesnelle, Honglu Fan, Enrico ShippoleICLR 2024 · 508 citations
  4. LongRoPE: Extending LLM Context Window Beyond 2 Million TokensYiran Ding, Li Lyna Zhang, Chengruidong Zhang, Yuanyuan Xu et al.ICML 2024 · 316 citations
  5. LongLoRA: Efficient Fine-tuning of Long-Context Large Language ModelsYukang Chen, Shengju Qian, Haotian Tang, Xin Lai et al.ICLR 2024 · 254 citations

Related papers

  1. Exploring Context Window of Large Language Models via Decomposed Positional VectorsZican Dong, Junyi Li, Xin Men, Xin Zhao et al.NeurIPS 2024 · 37 citations
  2. LaMPE: Length-aware Multi-grained Positional Encoding for Adaptive Long-context Scaling Without TrainingSikui Zhang, Guangze Gao, Ziyun Gan, Chunfeng Yuan et al.ACL Findings 2026
  3. PoSE: Efficient Context Window Extension of LLMs via Positional Skip-wise TrainingDawei Zhu, Nan Yang, Liang Wang, Yifan Song et al.ICLR 2024 · 110 citations
  4. Context Length Extension via Generalized Extrapolation ScaleLinhan Li, Huaping ZhangACL Findings 2024
  5. ReAttention: Training-Free Infinite Context with Finite Attention ScopeXiaoran Liu, Ruixiao Li, Zhigeng Liu, Qipeng Guo et al.ICLR 2025
Dusk over the sea between two cliffs drawn in fine vertical lines