arXiv:2412.07380cs.CLcs.AI2024-12NeurIPS被引 7

动态调整模型权重,让大模型协作更智能高效。

SpecFuse: Ensembling Large Language Models via Next-Segment Prediction

  • 基于片段预测实现模型间语义级协作,无需训练。
  • 实时根据表现优劣调整投票权重,强模型影响更大。
  • 在6个数据集上超越现有方法,适用于各类大模型融合。

生成式大语言模型(LLM)的集成是弥补单个模型缺陷的有效方式,可整合不同模型的优势。然而,现有集成方法存在首词延迟、长程语义协同困难等问题,且通常假设各模型投票权重相等,忽略其任务表现差异。本文提出SpecEM,一种无需训练、即插即用的LLM集成框架,能实时动态调整各模型贡献度。受推测解码启发,SpecEM通过迭代草稿与验证机制,实现模型在片段层面的语义协作。此外,引入在线反馈机制,采用乘法权重更新策略,根据模型在验证阶段胜出频率动态调节投票权重,确保表现更强的模型拥有更大影响力。在五个不同规模(7B至72B参数)的LLM家族及六个基准数据集上的实验表明,该方法在开放域指令遵循、推理、常识理解等任务中均显著优于现有先进集成方法。代码已公开于https://github.com/lvbotenbest/SpecEM。

原文摘要 · Abstract (English)

Ensembles of generative large language models (LLMs) are a promising way to compensate for individual model limitations, integrating the strengths of different LLMs. Existing LLM ensemble methods, however, face limitations such as first-token delay and challenges in long-range semantic collaboration between models, Moreover, they typically assume equal voting weights for all models during ensemble, ignoring task-specific performance differences among models. In this work, we propose SpecEM, a training-free, plug-and-play LLM ensemble framework that dynamically adjusts each model's model contribution in real time based on task performance. Inspired by speculative decoding, SpecEM iteratively performs drafting and verification, allowing models to collaborate semantically at the segment level for integrated output. Furthermore, we introduce an online feedback mechanism with multiplicative weight updates, where each model's voting weight is adjusted on-the-fly according to how often it outperforms others during verification stage, ensuring that stronger models exert greater influence during ensembling. Experimental results on five LLM families (ranging from 7B to 72B parameters) and six benchmark datasets, spanning open-domain instruction following, reasoning, commonsense, demonstrate consistent performance improvements compared to state-of-the-art LLM ensemble methods. Our code is available at https://github.com/lvbotenbest/SpecEM.

大模型集成动态权重推测解码

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。