Communication Dans Un Congrès Année : 2024

The N-Grammys: Accelerating Autoregressive Inference with Learning-Free Batched Speculation

Résumé

Speculative decoding aims to speed up autoregressive generation of a language model by verifying in parallel the tokens generated by a smaller draft model. In this work, we explore the effectiveness of learning-free, negligible-cost draft strategies, namely $N$-grams obtained from the model weights and the context. While the predicted next token of the base model is rarely the top prediction of these simple strategies, we observe that it is often within their top-$k$ predictions for small $k$. Based on this, we show that combinations of simple strategies can achieve significant inference speedups over different tasks. The overall performance is comparable to more complex methods, yet does not require expensive preprocessing or modification of the base model, and allows for seamless `plug-and-play' integration into pipelines.

Fichier principal
Vignette du fichier
main.pdf (632.02 Ko) Télécharger le fichier
Origine Fichiers produits par l'(les) auteur(s)
Licence

Dates et versions

hal-04766931 , version 1 (05-11-2024)

Licence

Identifiants

  • HAL Id : hal-04766931 , version 1

Citer

Lawrence Stewart, Matthew Trager, Sujan Kumar Gonugondla, Stefano Soatto. The N-Grammys: Accelerating Autoregressive Inference with Learning-Free Batched Speculation. ENLSP-IV 2024 - 4th NeurIPS Efficient Natural Language and Speech Processing Workshop, Dec 2024, Vancouver, Canada. ⟨hal-04766931⟩
120 Consultations
243 Téléchargements

Partager

  • More