arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2305.09781cs.CLcs.DCcs.LG
收藏

SpecInfer:基于树状推测推理与验证加速生成式大语言模型服务

SpecInfer: Accelerating Generative Large Language Model Serving with Tree-based Speculative Inference and Verification

Carnegie Mellon University(卡内基梅隆大学);Tsinghua University(清华大学);Stanford University(斯坦福大学);Shanghai Jiao Tong University(上海交通大学);Peking University(北京大学)
Xupeng Miao, Gabriele Oliaro, Zhihao Zhang, Xinhao Cheng, Zeyu Wang, Zhengxin Zhang, Rae Ying Yee Wong, Alan Zhu, Lijie Yang, Xiaoxiang Shi, Chunan Shi, Zhuomin… 展开作者

Xupeng Miao, Gabriele Oliaro, Zhihao Zhang, Xinhao Cheng, Zeyu Wang, Zhengxin Zhang, Rae Ying Yee Wong, Alan Zhu, Lijie Yang, Xiaoxiang Shi, Chunan Shi, Zhuoming Chen, Daiyaan Arfeen, Reyna Abhyankar, Zhihao Jia

AI总结:

SpecInfer通过小型推测模型生成令牌树预测,并用基于树的并行解码机制由LLM统一验证,在保持模型质量的同时将生成式LLM服务加速1.5至3.5倍。

摘要:

本文介绍了SpecInfer,一个通过基于树的推测推理与验证来加速生成式大语言模型(LLM)服务的系统。SpecInfer背后的核心思想是利用小型推测模型来预测LLM的输出;这些预测被组织成一棵令牌树,树中的每个节点代表一个候选令牌序列。通过一种新颖的基于树的并行解码机制,令牌树所表示的所有候选令牌序列的正确性可以并行地针对LLM进行验证。SpecInfer将LLM用作令牌树验证器而非增量解码器,这显著降低了服务生成式LLM的端到端延迟和计算需求,同时可证明地保持模型质量。我们的评估表明,SpecInfer在分布式LLM推理上比现有LLM服务系统快1.5至2.8倍,在基于卸载的LLM推理上快2.6至3.5倍,同时保持相同的生成性能。SpecInfer已在https://github.com/flexflow/FlexFlow/上公开提供。

英文摘要:

This paper introduces SpecInfer, a system that accelerates generative large language model (LLM) serving with tree-based speculative inference and verification. The key idea behind SpecInfer is leveraging small speculative models to predict the LLM's outputs; the predictions are organized as a token tree, whose nodes each represent a candidate token sequence. The correctness of all candidate token sequences represented by a token tree is verified against the LLM in parallel using a novel tree-based parallel decoding mechanism. SpecInfer uses an LLM as a token tree verifier instead of an incremental decoder, which significantly reduces the end-to-end latency and computational requirement for serving generative LLMs while provably preserving model quality. Our evaluation shows that SpecInfer outperforms existing LLM serving systems by 1.5-2.8x for distributed LLM inference and by 2.6-3.5x for offloading-based LLM inference, while preserving the same generative performance. SpecInfer is publicly available at https://github.com/flexflow/FlexFlow/

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑