A Call for Clarity in Beam Search: How It Works and When It Stops
Not on the map. Why?
Abstract (arXiv)
Text generation with beam search has proven successful in a wide range of applications. We point out that, though largely overlooked in the literature, the commonly-used implementation of beam decoding (e.g., Hugging Face Transformers and fairseq) uses a first come, first served heuristic: it keeps a set of already completed sequences over time steps and stops when the size of this set reaches the beam size. Based on this finding, we introduce a patience factor, a simple modification to this beam decoding implementation, that generalizes the stopping criterion and provides flexibility to the depth of search. Empirical results demonstrate that adjusting this patience factor improves decoding performance of strong pretrained models on news text summarization and machine translation over diverse language pairs, with a negligible inference slowdown. Our approach only modifies one line of code and can be thus readily incorporated in any implementation. Further, we find that different versions of beam decoding result in large performance differences in summarization, demonstrating the need for clarity in specifying the beam search implementation in research work. Our code will be available upon publication.
Key facts. Cited by 10 papers in the map (data through 7 Oct 2026). Builds on 122 of its 177 references that are in the map. First posted on arXiv 11 Apr 2022.
Builds on
122 of 177 references.
References · 122
- 2017Attention Is All You Needcited by 59,932
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2014Adam: A Method for Stochastic Optimizationcited by 36,960
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 29,915
- 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
- 2019RoBERTa: A Robustly Optimized BERT Pretraining Approachcited by 13,266
- 2015Distilling the Knowledge in a Neural Networkcited by 10,076
- 2019BART: Denoising Sequence-to-Sequence Pre-training for Natural Language Generation, Translation, and Comprehensioncited by 5,874
- 2018GLUE: A Multi-Task Benchmark and Analysis Platform for Natural Language Understandingcited by 4,854
- 2014Neural Machine Translation by Jointly Learning to Align and Translatecited by 4,530
- 2019DistilBERT, a distilled version of BERT: smaller, faster, cheaper and lightercited by 4,243
38 more
- 2019Parameter-Efficient Transfer Learning for NLPcited by 4,195
- 2016SQuAD: 100,000+ Questions for Machine Comprehension of Textcited by 4,115
- 2014Learning Phrase Representations using RNN Encoder-Decoder for Statistical Machine Translationcited by 4,016
- 2019Unsupervised Cross-lingual Representation Learning at Scalecited by 3,907
- 2016Pointer Sentinel Mixture Modelscited by 2,992
- 2014Sequence to Sequence Learning with Neural Networkscited by 2,974
- 2015Neural Machine Translation of Rare Words with Subword Unitscited by 2,898
- 2019XLNet: Generalized Autoregressive Pretraining for Language Understandingcited by 2,801
- 2017A Broad-Coverage Challenge Corpus for Sentence Understanding through Inferencecited by 2,665
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 1,979
- 2019Transformer-XL: Attentive Language Models Beyond a Fixed-Length Contextcited by 1,830
- 2018A Call for Clarity in Reporting BLEU Scorescited by 1,790
- 2020Big Bird: Transformers for Longer Sequencescited by 1,673
- 2020Reformer: The Efficient Transformercited by 1,658
- 2020Rethinking Attention with Performerscited by 1,584
- 2019Generating Long Sequences with Sparse Transformerscited by 1,523
- 2019fairseq: A Fast, Extensible Toolkit for Sequence Modelingcited by 1,486
- 2020Linformer: Self-Attention with Linear Complexitycited by 1,462
- 2017Bottom-Up and Top-Down Attention for Image Captioning and Visual Question Answeringcited by 1,310
- 2018Don't Give Me the Details, Just the Summary! Topic-Aware Convolutional Neural Networks for Extreme Summarizationcited by 1,308
- 2017Get To The Point: Summarization with Pointer-Generator Networkscited by 1,281
- 2020Oscar: Object-Semantics Aligned Pre-training for Vision-Language Taskscited by 1,213
- 2019PEGASUS: Pre-training with Extracted Gap-sentences for Abstractive Summarizationcited by 1,100
- 2015Fast and Accurate Deep Network Learning by Exponential Linear Units (ELUs)cited by 1,061
- 2015Aligning Books and Movies: Towards Story-like Visual Explanations by Watching Movies and Reading Bookscited by 1,041
- 2015Teaching Machines to Read and Comprehendcited by 1,039
- 2020COMET: A Neural Framework for MT Evaluationcited by 1,024
- 2016Abstractive Text Summarization Using Sequence-to-Sequence RNNs and Beyondcited by 809
- 2019Are Sixteen Heads Really Better than One?cited by 803
- 2020Efficient Transformers: A Surveycited by 784
- 2018Image Transformercited by 770
- 2019Compressive Transformers for Long-Range Sequence Modellingcited by 699
- 2020Long Range Arena: A Benchmark for Efficient Transformerscited by 696
- 2014Neural Turing Machinescited by 630
- 2018Universal Transformerscited by 613
- 2019Enhancing the Locality and Breaking the Memory Bottleneck of Transformer on Time Series Forecastingcited by 606
- 2019Defending Against Neural Fake Newscited by 553
- 2021Linear Transformers Are Secretly Fast Weight Programmerscited by 471
50 most cited of 122 All 122 (JSON)
Built on by
Citing papers per year: 2022: 2; 2023: 0; 2024: 1; 2025: 4; 2026: 3.
10 papers.
- 2022Revisiting the Gold Standard: Grounding Summarization Evaluation with Robust Human Evaluationcited by 141
- 2022Offline RL for Natural Language Generation with Implicit Language Q Learningcited by 137
- 2025Language Models, Graph Searching, and Supervision Adulteration: When More Supervision is Less and How to Make More Morecited by 3
- 2024HARP: Hesitation-Aware Reframing in Transformer Inference Passcited by 2
- 2025Latent Beam Diffusion Models for Generating Visual Sequencescited by 1
- 2025Customizing Speech Recognition Model with Large Language Model Feedbackcited by 1
- 2026Think Twice Before You Write -- an Entropy-based Decoding Strategy to Enhance LLM Reasoningcited by 1
- 2026Automated Summarization of Software Documents: An LLM-based Multi-Agent Approachcited by 1
- 2025Next Token Prediction Is a Dead End for Creativitycited by 0
- 2026Beam Search, Self-Consistency, and the Limits of Inference-Time Scaling for Grammar-Constrained Text-to-SQL in Small Language Modelscited by 0
- 2026Beam Search, Self-Consistency, and the Limits of Inference-Time Scaling for Grammar-Constrained Text-to-SQL in Small Language Models26 Aug 2026
- 2026Automated Summarization of Software Documents: An LLM-based Multi-Agent Approach23 Jun 2026
- 2026Think Twice Before You Write -- an Entropy-based Decoding Strategy to Enhance LLM Reasoning10 Mar 2026
- 2025Customizing Speech Recognition Model with Large Language Model Feedback5 Jun 2025
- 2025Next Token Prediction Is a Dead End for Creativity25 May 2025
- 2025Latent Beam Diffusion Models for Generating Visual Sequences26 Mar 2025
- 2025Language Models, Graph Searching, and Supervision Adulteration: When More Supervision is Less and How to Make More More13 Mar 2025
- 2024HARP: Hesitation-Aware Reframing in Transformer Inference Pass10 Dec 2024
- 2022Revisiting the Gold Standard: Grounding Summarization Evaluation with Robust Human Evaluation15 Dec 2022
- 2022Offline RL for Natural Language Generation with Implicit Language Q Learning5 Jun 2022