HackerPapers

arXiv:2012.15832cs.CL

Shortformer: Better Language Modeling using Shorter Inputs

Ofir Press, Noah A. Smith, Mike Lewis

Early discovery. Linked by one identifiable commenter. This paper is outside the main ranking; a mention is not an endorsement.

Abstract

Increasing the input length has been a driver of progress in language modeling with transformers. We identify conditions where shorter inputs are not harmful, and achieve perplexity and efficiency improvements through two new methods that decrease input length. First, we show that initially training a model on short subsequences before moving on to longer ones both reduces overall training time and, surprisingly, substantially improves perplexity. Second, we show how to improve the efficiency of recurrence methods in transformers, which let models condition on previously processed tokens when generating sequences that exceed the maximal length the transformer can handle at once. Existing methods require computationally expensive relative position embeddings; we introduce a simple alternative of adding absolute position embeddings to queries and keys instead of to word embeddings, which efficiently produces superior results. We show that these recurrent models also benefit from short input lengths. Combining these techniques speeds up training by a factor of 1.65, reduces memory usage, and substantially improves perplexity on WikiText-103, without adding any parameters.

arXiv comments
To appear at ACL 2021
Journal reference
DOI
Subjects
cs.CLComputation and Language

On Hacker News

Linked by 1 identifiable commenter in 1 comment across 1 thread, from Feb 2021 to Feb 2021.

Comments linking this paper, per year.

Discussed in comments1 thread

    • Modelling long sequences has always been hard for transformer-based models. This paper proposes a super innovative way for the transformer to cache previously processed tokens. And it makes generation 9X faster. This is truly mind-blowing Paper https://arxiv.org/abs/2012.15832…

      deeplstmView on HNParent context

Submitted to Hacker News

Connected through shared HN threads, not inferred similarity or a recommendation.