YaRN: Efficient Context Window Extension of Large Language Models

By Bowen Peng, Jeffrey Quesnelle, Honglu Fan, Enrico Shippole. 2023

587 citations recorded by the source corpus.

Rotary Position Embeddings (RoPE) have been shown to effectively encode positional information in transformer-based language models. However, these models fail to generalize past the sequence length they were trained on. We present YaRN (Yet another RoPE extensioN method), a compute-efficient method to extend the context window of such models, requiring 10x less tokens and 2.5x less training steps than previous methods. Using YaRN, we show that LLaMA models can effectively utilize and extrapolate to context lengths much longer than their original pre-training would allow, while also surpassing previous the state-of-the-art at context window extension. In addition, we demonstrate that YaRN exhibits the capability to extrapolate beyond the limited context of a fine-tuning dataset. Code is available at https://github.com/jquesnelle/yarn

Subfields: Artificial Intelligence, Large Language Models, Efficiency & Compression

How researchers see this paper

The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.

In Artificial Intelligence

  1. Luke S. Zettlemoyer
  2. Yuandong Tian
  3. Bo Li
  4. Mohit Bansal
  5. Quoc V. Le
  6. Song Han
  7. Yashar Mehdad
  8. Madian Khabsa

In Large Language Models

  1. Damai Dai
  2. Bo Li
  3. Song Han
  4. Fei Huang
  5. Zhihong Shao
  6. Jingren Zhou
  7. Sergey Edunov
  8. Madian Khabsa

In Efficiency & Compression

  1. Yuandong Tian
  2. Beidi Chen
  3. Sharan Narang
  4. Guangxuan Xiao
  5. Song Han
  6. Damai Dai
  7. Bo Li
  8. Fei Huang

Citations in the corpus