Scaling Large Language Models (LLMs) typically relies on increasing the number of parameters or test-time computations to boost performance. However, these strategies are impractical for edge device deployment due to limited RAM and NPU resources. Despite hardware constraints, deploying performant LLM on edge devices such as smartphone remains crucial for user experience. To address this, we propose MeKi (Memory-based Expert Knowledge Injection), a novel system that scales LLM capacity via storage space rather than FLOPs. MeKi equips each Transformer layer with token-level memory experts that injects pre-stored semantic knowledge into the generation process. To bridge the gap between training capacity and inference efficiency, we employ a re-parameterization strategy to fold parameter matrices used during training into a compact static lookup table. By offloading the knowledge to ROM, MeKi decouples model capacity from computational cost, introducing zero inference latency overhead. Extensive experiments demonstrate that MeKi significantly outperforms dense LLM baselines with identical inference speed, validating the effectiveness of memory-based scaling paradigm for on-device LLMs. Project homepage is at https://github.com/ningding-o/MeKi.


翻译:扩展大语言模型(LLMs)通常依赖于增加参数数量或测试时计算量以提升性能。然而,由于边缘设备的内存和神经处理单元资源有限,这些策略在实际部署中并不适用。尽管存在硬件限制,在智能手机等边缘设备上部署高性能LLM对于用户体验仍至关重要。为此,我们提出MeKi(基于内存的专家知识注入),这是一种通过存储空间而非浮点运算量来扩展LLM能力的新颖系统。MeKi为每个Transformer层配备了令牌级记忆专家模块,将预存储的语义知识注入生成过程。为弥合训练容量与推理效率之间的差距,我们采用重参数化策略,将训练期间使用的参数矩阵折叠为紧凑的静态查找表。通过将知识卸载到只读存储器,MeKi实现了模型容量与计算成本的解耦,且不引入任何推理延迟开销。大量实验表明,在相同推理速度下,MeKi显著优于稠密LLM基线模型,验证了基于内存的扩展范式在设备端LLM部署中的有效性。项目主页位于 https://github.com/ningding-o/MeKi。

0
下载
关闭预览

相关内容

移动边缘智能与大型语言模型综述
专知会员服务
40+阅读 · 2024年7月31日
国家自然科学基金
18+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
11+阅读 · 2012年12月31日
VIP会员
相关VIP内容
移动边缘智能与大型语言模型综述
专知会员服务
40+阅读 · 2024年7月31日
相关基金
国家自然科学基金
18+阅读 · 2017年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
11+阅读 · 2012年12月31日
Top
微信扫码咨询专知VIP会员