提出新采样器,让循环深度模型生成速度提升5倍。
Efficient Parallel Samplers for Recurrent-Depth Models and Their Connection to Diffusion Language Models
- 通过扩散采样思想,每轮前向传播生成多个新词元。
- 在相同时间内,生成能力比传统自回归更强。
- 无需调参即可用于35亿参数模型,适合高效推理场景。
具有循环深度的语言模型(又称循环变压器)可通过重复层增加计算量。近期预训练研究表明,这类架构在现代语言建模任务中表现优异,并在推理任务中具备优势。本文探讨了循环深度模型与扩散语言模型之间的联系,基于相似性设计了一种新的扩散强制采样器,以加速生成过程。该采样器在每次前向传播中解码多个新词元,同时可并行精炼这些词元的潜在状态。理论上,在现代硬件的相同时间预算下,该方法生成能力严格优于基线自回归生成。此外,该采样器基于扩散理论,可直接应用于现有的3.5B参数循环深度变压器,无需调参,实现最高5倍的速度提升。因此,本研究不仅为循环深度模型的推理阶段提供了高效的并行化机制,还表明此类模型可自然视为强连续但因果的扩散语言模型。
原文摘要 · Abstract (English)
Language models with recurrent depth, also referred to as universal or looped when considering transformers, are defined by the capacity to increase their computation through the repetition of layers. Recent efforts in pretraining have demonstrated that these architectures can scale to modern language modeling tasks while exhibiting advantages in reasoning tasks. In this work, we examine the relationship between recurrent-depth models and diffusion language models. Building on their similarities, we develop a new diffusion forcing sampler for these models to accelerate generation. The sampler advances by decoding new tokens at every forward pass of the model, while the latent states of these tokens can be further refined in parallel through recurrence. Theoretically, generation with our sampler is strictly more expressive than the baseline autoregressive generation using the same time budget on modern hardware. Moreover, this sampler, based on principles from diffusion literature, can be directly applied to existing 3.5B recurrent-depth transformers without any tuning, leading to up to a 5x speedup. Consequently, our findings not only provide an efficient mechanism for parallelizing the extra computation in recurrent-depth models at inference, but also suggest that such models can be naturally viewed as strong continuous, though causal, diffusion language models.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。