RECAP:面向多模态投机解码的预测回收方法
RECAP: Context-Aware Prediction Recycling with Request-Local and Persistent Memories for Multimodal Speculative Decoding
免训练不换草稿模型,直接给 Qwen2.5-VL 和 LLaVA 视觉模型推理提速 1.5 倍以上,代码开源可以自己跑。
arXiv 论文 RECAP 提出一种免训练的多模态投机解码方法,用单、双、三 token 键存储目标模型预测,解决 vision-language 模型中按最后 token 索引导致的图像混淆问题。上下文记忆仅在当前请求内生效,token 级记忆跨请求保留覆盖率,通过熵置信度加权融合检索结果。在 Qwen2.5-VL-7B 和 LLaVA-1.6-7B 的七项单轮基准上分别取得 1.66x 和 1.56x 平均加速,超过免训练最强基线 Token Recycling 的 1.51x 和 1.37x。代码已在 GitHub 开源。
RECAP: Context-Aware Prediction Recycling with Request-Local and Persistent Memories for Multimodal Speculative Decoding
Recycling a target model's own predictions offers a training-free source of proposals for speculative decoding. In vision-language models, however, existing recycling indexes predictions by the last token alone, conflating predictions computed under different images and prefixes; we find that such reuse fails most often at image-sensitive decoding states. Longer keys reduce this aliasing but match fewer states. We introduce \method, which stores target predictions under one-, two-, and three-token keys: contextual memories live only for the current request and are thus implicitly conditioned on its image, while token-level memory persists across requests to retain coverage. At each lookup, entropy-confidence weighting fuses the retrieved predictions according to their key specificity and concentration. Best-first search composes the fused transitions into a candidate tree, supplemented by suffix-matched continuations, and one target pass verifies the tree under greedy decoding. Without training or an auxiliary draft model, \method\ achieves mean speedups over autoregressive decoding of $1.66\speed$ and $1.56\speed$ across seven single-turn benchmarks on Qwen2.5-VL-7B and LLaVA-1.6-7B, exceeding the strongest training-free baseline, Token Recycling ($1.51\speed$ and $1.37\speed$). Our implementation is available in https://github.com/Senmo996/RECAP-official-code.