paper-with-me

홈 › Papers

The EOS Decision and Length Extrapolation

2020-10-14 · EMNLP (BlackboxNLP) 2020 11 · Benjamin Newman, John Hewitt, Percy Liang, Christopher D. Manning

Extrapolation to unseen sequence lengths is a challenge for neural generative models of language. In this work, we characterize the effect on length extrapolation of a modeling decision often overlooked: predicting the end of the generative process through the use of a special end-of-sequence (EOS) vocabulary item. We study an oracle setting - forcing models to generate to the correct sequence length at test time - to compare the length-extrapolative behavior of networks trained to predict EOS (+EOS) with networks not trained to (-EOS). We find that -EOS substantially outperforms +EOS, for example extrapolating well to lengths 10 times longer than those seen at training time in a bracket closing task, as well as achieving a 40% improvement over +EOS in the difficult SCAN dataset length generalization task. By comparing the hidden states and dynamics of -EOS and +EOS models, we observe that +EOS models fail to generalize because they (1) unnecessarily stratify their hidden states by their linear position is a sequence (structures we call length manifolds) or (2) get stuck in clusters (which we refer to as length attractors) once the EOS token is the highest-probability prediction.

📄 PDF Abstract BibTeX arXiv:2010.07174

Code (1)

bnewm0609/eos-decision 공식 구현 pytorch

Similar Papers 제목 키워드 기반

Scaling Laws of RoPE-based Extrapolation

2023-10-08 · Xiaoran Liu, Hang Yan, Shuo Zhang, Chenxin An 외

The extrapolation capability of Large Language Models (LLMs) based on Rotary Position Embedding is currently a topic of considerable interest. The mainstream approach to addressing extrapolation with LLMs involves modify…

16k

CLEX: Continuous Length Extrapolation for Large Language Models

2023-10-25 · Guanzheng Chen, Xin Li, Zaiqiao Meng, Shangsong Liang 외

Transformer-based Large Language Models (LLMs) are pioneering advances in many natural language processing tasks, however, their exceptional capabilities are restricted within the preset context window of Transformer. Po…

4kPosition

Context-aware Biases for Length Extrapolation

2025-03-11 · Ali Veisi, Amir Mansourian

Transformers' ability to generalize to longer sequences than they have been trained on, known as length extrapolation, degrades as sequence length increases. Most of Relative Positional Encoding (RPE) methods address thi…

Decoder

Length Extrapolation of Transformers: A Survey from the Perspective of Positional Encoding

2023-12-28 · Liang Zhao, Xiachong Feng, Xiaocheng Feng, Weihong Zhong 외

Built upon the Transformer, large language models (LLMs) have captured worldwide attention due to their remarkable abilities. Nevertheless, all Transformer-based models including LLMs suffer from a preset length limit an…

PositionSurvey

KERPLE: Kernelized Relative Positional Embedding for Length Extrapolation

2022-05-20 · Ta-Chung Chi, Ting-Han Fan, Peter J. Ramadge, Alexander I. Rudnicky

Relative positional embeddings (RPE) have received considerable attention since RPEs effectively model the relative distance among tokens and enable length extrapolation. We propose KERPLE, a framework that generalizes r…

DiversityLanguage ModelingLanguage ModellingPosition