Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

Ouroboros: Generating Longer Drafts Phrase by Phrase for Faster Speculative Decoding

About

Speculative decoding is a widely used method that accelerates the generation process of large language models (LLMs) with no compromise in model performance. It achieves this goal by using an existing smaller model for drafting and then employing the target LLM to verify the draft in a low-cost parallel manner. Under such a drafting-verification framework, drafting efficiency has become a bottleneck in the final speedup of speculative decoding. Therefore, generating longer drafts at less cost can lead to better decoding speedup. To achieve this, we introduce Ouroboros, which can generate draft phrases to parallelize the drafting process and meanwhile lengthen drafts in a training-free manner. The experimental results on various typical text generation tasks show that Ouroboros can achieve speedups of up to $2.8\times$ over speculative decoding and $3.9\times$ over vanilla decoding, without fine-tuning draft and target models. The source code of Ouroboros is available at https://github.com/thunlp/Ouroboros.

Weilin Zhao, Yuxiang Huang, Xu Han, Wang Xu, Chaojun Xiao, Xinrong Zhang, Yewei Fang, Kaihuo Zhang, Zhiyuan Liu, Maosong Sun• 2024

Related benchmarks

TaskDatasetResultRank
Mathematical ReasoningGSM8K
Speed Up (x)2.89
177
Instruction FollowingAlpaca
Speedup (x)2.64
63
Multi-turn dialogueMT-Bench
Speedup2.36
47
Code GenerationHumanEval
Average Tau (τ)8.36
45
SummarizationCNN/DM
M Score5.97
35
Code GenerationHumanEval
Functional Score M6.38
29
Showing 6 of 6 rows

Other info

Follow for update