将预训练大模型转为高效稀疏专家模型,提升推理速度与资源利用。
Read-ME: Refactorizing LLMs as Router-Decoupled Mixture of Experts with System Co-Design
- 通过激活稀疏性提取专家,重构模型结构以支持高效推理。
- 在相同规模下,MMLU得分提升10.1%,端到端延迟降低6.1%。
- 适合资源受限场景下的大模型部署,尤其关注推理优化的开发者。
大型语言模型(LLM)的普及推动了混合专家(MoE)架构的发展,该架构通过动态调用专用子网络提升效率与性能。然而,由于模型架构与系统策略设计不匹配,现有MoE模型在推理阶段面临内存管理低效和批处理不佳的问题。此外,从头训练MoE的成本日益高昂。本文提出新框架Read-ME,将预训练的密集型LLM转化为更小的MoE模型(而非“升级”通用MoE),避免高昂的训练成本。方法基于激活稀疏性提取专家,并分析层间路由器设计冗余,引入与主干解耦的预门控路由器,支持系统友好的预计算与前瞻调度,提升专家感知的批处理与缓存效率。该软硬件协同设计同时解决算法与系统层面的关键问题,为资源受限环境下的LLM推理提供可扩展、高效的替代方案。Read-ME在相似规模下超越其他开源密集模型,在MMLU上最高提升10.1%,平均端到端延迟降低6.1%。代码已公开:https://github.com/VITA-Group/READ-ME。
原文摘要 · Abstract (English)
The proliferation of large language models (LLMs) has led to the adoption of Mixture-of-Experts (MoE) architectures that dynamically leverage specialized subnetworks for improved efficiency and performance. Despite their benefits, MoE models face significant challenges during inference, including inefficient memory management and suboptimal batching, due to misaligned design choices between the model architecture and the system policies. Furthermore, the conventional approach of training MoEs from scratch is increasingly prohibitive in terms of cost. In this paper, we propose a novel framework Read-ME that transforms pre-trained dense LLMs into smaller MoE models (in contrast to "upcycling" generalist MoEs), avoiding the high costs of ground-up training. Our approach employs activation sparsity to extract experts. To compose experts, we examine the widely-adopted layer-wise router design and show its redundancy, and thus we introduce the pre-gating router decoupled from the MoE backbone that facilitates system-friendly pre-computing and lookahead scheduling, enhancing expert-aware batching and caching. Our codesign therefore addresses critical gaps on both the algorithmic and system fronts, establishing a scalable and efficient alternative for LLM inference in resource-constrained settings. Read-ME outperforms other popular open-source dense models of similar scales, achieving improvements of up to 10.1% on MMLU, and improving mean end-to-end latency up to 6.1%. Codes are available at: https://github.com/VITA-Group/READ-ME.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。