Accordion:基于固定前缀层循环的弹性深度推理 Accordion: Elastic-Depth Inference via Fixed-Prefix Layer Looping 预印本

⚠️ 本文为 预印本(arXiv 公开版本),尚未经过正式同行评审。作者自发公开,结论未经期刊审稿验证,阅读时请知悉。
发布时间:2026-10-23
👁️ 预览文献
💡 AI 中文简介
大型语言模型需适应不同推理预算,但为每个预算单独训练模型成本高昂。本文提出Accordion,一种基于混合专家(MoE)的模型,通过固定前缀层循环支持五种推理预算,每个预算对应预定义的执行路径,最小预算保留未循环模型。联合预训练时每个微批次采样一个预算并优化下一词预测损失,无需跨预算一致性目标。通过监督微调和强化学习(参数组合并与预算匹配的多教师在线策略蒸馏)将三个领域专家整合为一个模型。在3.6万亿token预训练后,增加推理深度使Accordion-6B-A0.5B在37个任务上的五类宏平均提升3.01个百分点,中间预算以一半额外层执行获得89%的增益。最终模型在各领域任务-预算平均上超越对应专家,所有预算下指令跟随性能强,并在数学推理和代码生成上保持深度相关增益。
领域自然语言处理 / 高效推理与模型压缩
适合谁读需要一定专业背景(熟悉Transformer、MoE、蒸馏等概念)
核心贡献1. 提出基于固定前缀层循环的弹性深度推理框架,单一模型支持五种推理预算,无需为每个预算单独训练;2. 通过参数组合并与预算匹配的多教师在线策略蒸馏,将多个领域专家整合为一个模型,并在各预算下保持强性能。
关键数据预训练3.6T token;Accordion-6B-A0.5B在37个任务上五类宏平均提升3.01个百分点;中间预算以一半额外层执行获得89%的增益;最终模型在各领域任务-预算平均上超越对应专家。
推荐理由想用单一模型灵活适配不同算力预算?Accordion用层循环和MoE实现弹性推理,性能提升显著,值得一读!
关键词["弹性推理", "层循环", "混合专家", "推理预算", "模型压缩", "知识蒸馏"]

原文摘要

查看英文原文摘要

Large language models serve applications with diverse inference budgets, but training and maintaining separate models for each budget incurs substantial costs. Recent Looped Transformers enable flexible inference computation through parameter reuse, but maintaining strong performance across different inference budgets remains an open challenge. We introduce Accordion, a mixture-of-experts-based model that supports five inference budgets through fixed-prefix layer looping. Each budget follows a pre-defined execution path, while the minimum budget retains the unlooped model. Joint pretraining samples one budget per micro-batch and optimizes its next-token prediction loss without additional cross-budget consistency objectives. We further preserve these inference budgets through supervised fine-tuning and reinforcement learning, where parameter-group merging and budget-matched multi-teacher on-policy distillation integrate three domain experts into one model. After 3.6T tokens of pretraining, increasing inference depth improves Accordion-6B-A0.5B's five-category macro-average across 37 tasks by 3.01 percentage points, with the middle budget capturing 89% of this gain using half as many additional layer executions. The final model surpasses each domain expert on its corresponding task-and-budget average, while achieving strong instruction-following performance across all budgets and retaining depth-dependent gains in mathematical reasoning and code generation.