Deploying large language models (LLMs) on edge devices is challenging due to their limited memory and power resources. Cloud-only inference reduces device burden but introduces high latency and cost. Static edge-cloud partitions optimize a single metric and struggle when bandwidth fluctuates. We propose Splitwise, a novel Lyapunov-assisted deep reinforcement learning (DRL) framework for fine-grained, adaptive partitioning of LLMs across edge and cloud environments. Splitwise decomposes transformer layers into attention heads and feed-forward sub-blocks, exposing more partition choices than layer-wise schemes. A hierarchical DRL policy, guided by Lyapunov optimization, jointly minimizes latency, energy consumption, and accuracy degradation while guaranteeing queue stability under stochastic workloads and variable network bandwidth. Splitwise also guarantees robustness via partition checkpoints with exponential backoff recovery in case of communication failures. Experiments on Jetson Orin NX, Galaxy S23, and Raspberry Pi 5 with GPT-2 (1.5B), LLaMA-7B, and LLaMA-13B show that Splitwise reduces end-to-end latency by 1.4x-2.8x and cuts energy consumption by up to 41% compared with existing partitioners. It lowers the 95th-percentile latency by 53-61% relative to cloud-only execution, while maintaining accuracy and modest memory requirements.


翻译:由于内存和功耗资源受限,在边缘设备上部署大型语言模型(LLM)面临挑战。纯云端推理虽减轻设备负担,却会引入高延迟与成本。静态边缘-云划分方案仅针对单一指标优化,难以适应带宽波动。本文提出Splitwise——一种基于李雅普诺夫辅助深度强化学习(DRL)的新型框架,可实现LLM在边缘与云环境间的细粒度自适应划分。该框架将Transformer层分解为注意力头与前馈子模块,相比逐层划分方案提供了更丰富的划分选择。通过李雅普诺夫优化引导的分层DRL策略,系统在随机工作负载和动态网络带宽条件下联合优化延迟、能耗与精度损失,同时保证队列稳定性。Splitwise还通过划分检查点机制保障鲁棒性,在通信故障时采用指数退避策略进行恢复。在Jetson Orin NX、Galaxy S23和树莓派5设备上,使用GPT-2(1.5B)、LLaMA-7B和LLaMA-13B模型的实验表明:相较于现有划分器,Splitwise将端到端延迟降低1.4-2.8倍,能耗最高减少41%;相比纯云端执行,其第95百分位延迟降低53-61%,同时保持精度并仅需适度内存开销。

0
下载
关闭预览

相关内容

【ECCV2022】对比视觉Transformer的在线持续学习
专知会员服务
23+阅读 · 2022年7月29日
AAAI 2022 | ProtGNN:自解释图神经网络
专知
10+阅读 · 2022年2月28日
图机器学习 2.2-2.4 Properties of Networks, Random Graph
图与推荐
10+阅读 · 2020年3月28日
读论文Discriminative Deep Metric Learning for Face and KV
统计学习与视觉计算组
12+阅读 · 2018年4月6日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
6+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
VIP会员
相关资讯
AAAI 2022 | ProtGNN:自解释图神经网络
专知
10+阅读 · 2022年2月28日
图机器学习 2.2-2.4 Properties of Networks, Random Graph
图与推荐
10+阅读 · 2020年3月28日
读论文Discriminative Deep Metric Learning for Face and KV
统计学习与视觉计算组
12+阅读 · 2018年4月6日
相关基金
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
46+阅读 · 2015年12月31日
国家自然科学基金
6+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
Top
微信扫码咨询专知VIP会员