arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2502.12455cs.CL
收藏

DSMoE:面向计算高效型稠密LLM的矩阵分区专家与动态路由

DSMoE: Matrix-Partitioned Experts with Dynamic Routing for Computation-Efficient Dense LLMs

Institute of Information Engineering, Chinese Academy of Sciences(中国科学院信息工程研究所);University of Chinese Academy of Sciences(中国科学院大学);Kuaishou Technology(快手科技);Tianjin University(天津大学);Tsinghua University(清华大学)

Minxuan Lv, Zhenpeng Su, Leiyu Pan, Yizhe Xiong, Zijia Lin, Hui Chen, Wei Zhou, Jungong Han, Guiguang Ding, Cheng Luo, Di Zhang, Kun Gai, Songlin Hu

AI总结:

提出DSMoE方法,通过将预训练FFN层划分为计算块并采用自适应专家路由与稀疏损失,在同等计算约束下实现了优于剪枝和MoE方法的性能。

摘要:

随着大语言模型不断扩展,计算成本与资源消耗已成为重大挑战。尽管剪枝等现有稀疏化方法能降低计算开销,但它们会因移除参数而面临丢失模型知识的风险。本文提出DSMoE(Dynamic Sparse Mixture-of-Experts,动态稀疏混合专家),这是一种通过将预训练FFN层划分为计算块来实现稀疏化的新方法。我们使用sigmoid激活和直通估计器实现自适应专家路由,使token能根据输入复杂度灵活访问模型知识的不同方面。此外,我们引入稀疏损失项以平衡性能与计算效率。在LLaMA模型上的大量实验表明,在同等计算约束下,DSMoE在语言建模和下游任务中的性能优于现有的剪枝和MoE方法,尤其在生成任务中表现突出。分析显示,DSMoE学习到独特的分层激活模式,为未来MoE架构设计提供了新见解。

英文摘要:

As large language models continue to scale, computational costs and resource consumption have emerged as significant challenges. While existing sparsification methods like pruning reduce computational overhead, they risk losing model knowledge through parameter removal. This paper proposes DSMoE (Dynamic Sparse Mixture-of-Experts), a novel approach that achieves sparsification by partitioning pre-trained FFN layers into computational blocks. We implement adaptive expert routing using sigmoid activation and straight-through estimators, enabling tokens to flexibly access different aspects of model knowledge based on input complexity. Additionally, we introduce a sparsity loss term to balance performance and computational efficiency. Extensive experiments on LLaMA models demonstrate that under equivalent computational constraints, DSMoE achieves superior performance compared to existing pruning and MoE approaches across language modeling and downstream tasks, particularly excelling in generation tasks. Analysis reveals that DSMoE learns distinctive layerwise activation patterns, providing new insights for future MoE architecture design.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑