Year: 2023
Type: preprint
Abstract: We introduce Retrieval-Based Speculative Decoding (REST), a novel algorithm designed to speed up language model generation. The key insight driving the development of REST is the observation that the process of text generation often includes certain common phases and patterns. Unlike previous methods that rely on a draft language model for speculative decoding, REST harnesses the power of retrieval to generate draft tokens. This method draws from the reservoir of existing knowledge, retrieving and employing relevant tokens based on the current context. Its plug-and-play nature allows for seamless integration and acceleration of any language models, all without necessitating additional training. When benchmarked on 7B and 13B language models in a single-batch setting, REST achieves a significant speedup of 1.62X to 2.36X on code or text generation. The code of REST is available at https://github.com/FasterDecoding/REST.
Source: arXiv (Cornell University)
Institutions: Peking University, Princeton University
Language: English
Subfield: Artificial Intelligence
Field: Computer Science
Domain: Physical Sciences
Open Access status: green
Awards: Collaborative Research: CIF: Medium: MoDL:Toward a Mathematical Foundation of Deep Reinforcement Learning, G2384362821, CAREER: Towards a Theory of Deep Learning, CIF: Medium: Collaborative Research: Theory of Optimization Geometry and Algorithms for Neural Networks, G6671297155, G7452299184, G862988727, RI: Medium: Provable Reinforcement Learning with Function Approximation and Neural Networks
OpenAlex ID: W4388717510
