EMNLP 2024main6 citations

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

Weilin Zhao, Yuxiang Huang, Xu Han, Wang Xu, Chaojun Xiao, Xinrong Zhang, Yewei Fang, Kaihuo Zhang

Abstract

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.4× over speculative decoding and 3.9× over vanilla decoding, without fine-tuning draft and target models. Code available at https://github.com/thunlp/Ouroboros.

BibTeX
@inproceedings{zhao-etal-2024-ouroboros,
    title = "Ouroboros: Generating Longer Drafts Phrase by Phrase for Faster Speculative Decoding",
    author = "Zhao, Weilin  and
      Huang, Yuxiang  and
      Han, Xu  and
      Xu, Wang  and
      Xiao, Chaojun  and
      Zhang, Xinrong  and
      Fang, Yewei  and
      Zhang, Kaihuo  and
      Liu, Zhiyuan  and
      Sun, Maosong",
    editor = "Al-Onaizan, Yaser  and
      Bansal, Mohit  and
      Chen, Yun-Nung",
    booktitle = "Proceedings of the 2024 Conference on Empirical Methods in Natural Language Processing",
    month = nov,
    year = "2024",
    address = "Miami, Florida, USA",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2024.emnlp-main.742/",
    doi = "10.18653/v1/2024.emnlp-main.742",
    pages = "13378--13393"
}
Ouroboros: Generating Longer Drafts Phrase by Phrase for Faster Speculative Decoding · EMNLP 2024