Jie Ou, Yueming Chen, Buyao Xiong, Zhaokun Wang, Wenhong Tian
{"title":"Accelerating Mixture-of-Experts language model inference via plug-and-play lookahead gate on a single GPU","authors":"Jie Ou, Yueming Chen, Buyao Xiong, Zhaokun Wang, Wenhong Tian","doi":"10.1016/j.csi.2025.103996","DOIUrl":null,"url":null,"abstract":"<div><div>The widespread adoption of large language models (LLMs) has encouraged researchers to explore strategies for running these models more efficiently, such as the mixture of experts (MoE) method, which aims to increase the knowledge capacity of the model without substantially increasing its computational costs, as only a fraction of the model components are active for each token. However, this approach also increases the size of the model, which makes it challenging to run these models even on high-end GPUs. Quantization and offloading strategies have been used to enable the execution of MoE in resource-constrained environments, however, the time overhead introduced by offloading remains a bottleneck. In this paper, we propose a plug-and-play lookahead gate that predicts in advance the experts to be used in the next few layers. Furthermore, to mitigate the misalignment problem arising from cross-layer prediction, we introduce an alignment training method, layer-wise gate alignment, enhancing the prediction hit rate while maintaining low resource requirements. Moreover, we present a speculative expert scheduling strategy to accelerate the end-to-end inference process of MoE models. To validate our approach, we established an inference framework for quantized MoE and conducted extensive experiments. The results demonstrate the effectiveness of our proposed methods, with throughput improvements of 57.72%, 60.00%, and 62.26% under 4, 3, and 2-bit quantization conditions for experts, respectively, compared with the Mixtral-offloading method.</div></div>","PeriodicalId":50635,"journal":{"name":"Computer Standards & Interfaces","volume":"94 ","pages":"Article 103996"},"PeriodicalIF":4.1000,"publicationDate":"2025-03-08","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Computer Standards & Interfaces","FirstCategoryId":"94","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S092054892500025X","RegionNum":2,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q1","JCRName":"COMPUTER SCIENCE, HARDWARE & ARCHITECTURE","Score":null,"Total":0}
引用次数: 0
Abstract
The widespread adoption of large language models (LLMs) has encouraged researchers to explore strategies for running these models more efficiently, such as the mixture of experts (MoE) method, which aims to increase the knowledge capacity of the model without substantially increasing its computational costs, as only a fraction of the model components are active for each token. However, this approach also increases the size of the model, which makes it challenging to run these models even on high-end GPUs. Quantization and offloading strategies have been used to enable the execution of MoE in resource-constrained environments, however, the time overhead introduced by offloading remains a bottleneck. In this paper, we propose a plug-and-play lookahead gate that predicts in advance the experts to be used in the next few layers. Furthermore, to mitigate the misalignment problem arising from cross-layer prediction, we introduce an alignment training method, layer-wise gate alignment, enhancing the prediction hit rate while maintaining low resource requirements. Moreover, we present a speculative expert scheduling strategy to accelerate the end-to-end inference process of MoE models. To validate our approach, we established an inference framework for quantized MoE and conducted extensive experiments. The results demonstrate the effectiveness of our proposed methods, with throughput improvements of 57.72%, 60.00%, and 62.26% under 4, 3, and 2-bit quantization conditions for experts, respectively, compared with the Mixtral-offloading method.
期刊介绍:
The quality of software, well-defined interfaces (hardware and software), the process of digitalisation, and accepted standards in these fields are essential for building and exploiting complex computing, communication, multimedia and measuring systems. Standards can simplify the design and construction of individual hardware and software components and help to ensure satisfactory interworking.
Computer Standards & Interfaces is an international journal dealing specifically with these topics.
The journal
• Provides information about activities and progress on the definition of computer standards, software quality, interfaces and methods, at national, European and international levels
• Publishes critical comments on standards and standards activities
• Disseminates user''s experiences and case studies in the application and exploitation of established or emerging standards, interfaces and methods
• Offers a forum for discussion on actual projects, standards, interfaces and methods by recognised experts
• Stimulates relevant research by providing a specialised refereed medium.