用概率电路实现快速多字节预测,兼顾生成速度与准确性
Fast and Expressive Multi-Byte Prediction with Probabilistic Circuits
- 基于概率电路构建联合分布模型,支持多种架构灵活表达
- 相比独立假设方法提速显著,且不降低原模型性能
- 适合追求高效推理的字节级大模型研究者使用
多标记预测(MTP)是显著加速大语言模型(LLM)生成的重要策略,尤其在无分词器的字节级LLM中尤为关键,但现有方法或假设未来标记独立导致表达力不足,或逐个生成标记增加延迟。本文提出基于概率电路(PC)的MTP框架——MTPC,通过选择不同电路结构来建模未来标记的联合分布,可统一经典模型如分层混合模型、隐马尔可夫模型和张量网络。实验表明,在EvaByte和Llama3.2 3B等字节级模型上结合推测解码,MTPC相比独立假设的MTP大幅加速生成,同时保证原验证模型性能不变。我们还系统研究了不同参数化方式(如电路架构、部分层共享)下表达力与延迟的最优权衡。
原文摘要 · Abstract (English)
Multi-token prediction (MTP) is a prominent strategy to significantly speed up generation in large language models (LLMs), especially in byte-level LLMs, which are tokeniser-free but prohibitively slow. However, many existing MTP methods either assume independence between future tokens, sacrificing expressiveness, or generate tokens one at a time within the window, increasing latency. In this work, we investigate the trade-off between expressiveness and latency in MTP within the framework of probabilistic circuits (PCs). Our framework, MTPC, allows one to explore different ways to encode the joint distributions over future tokens by selecting circuit architectures, generalising classical models such as (hierarchical) mixture models, hidden Markov models, and tensor networks. We show the efficacy of MTPC by retrofitting existing byte-level LLMs, such as EvaByte, and byte-fied subword models, such as Llama3.2 3B. Our experiments show that, when combined with speculative decoding, MTPC substantially speeds up generation compared to MTP with independence assumptions, while guaranteeing to retain the performance of the original verifier LLM. We also rigorously study the optimal trade-off between expressiveness and latency when exploring the possible parameterisations of MTPC, such as PC architectures and partial layer sharing between the verifier and draft LLMs.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。