Large Language Models (LLMs) are increasingly deployed in complex multi-agent applications that rely on external function calls. This workload creates severe performance challenges for the KV Cache: spatial contention leads to the eviction of critical agents' caches and temporal underutilization leaves the cache of agents stalled on long-running function calls idling in GPU memory. We present TokenCake, a KV-Cache-centric serving framework that bridges this gap by co-optimizing scheduling and memory management through an agent-aware design. TokenCake's Temporal Scheduler employs an event-driven, opportunistic policy to proactively offload idle KV Caches during function calls and uses predictive uploading to hide data transfer latency. TokenCake's Spatial Scheduler uses dynamic memory partitioning, guided by a hybrid priority metric combining graph structure and runtime state, to reserve GPU memory for critical-path agents. Our evaluation on representative multi-agent benchmarks shows that TokenCake reduces end-to-end latency by over 47.06% and improves effective GPU memory utilization by up to 16.9% compared to vLLM.


翻译:大型语言模型(LLM)正被日益部署于依赖外部函数调用的复杂多智能体应用中。此类工作负载对KV缓存造成了严峻的性能挑战:空间竞争导致关键智能体的缓存被逐出,而时间利用不足又使因长函数调用而阻塞的智能体缓存闲置在GPU显存中。我们提出TokenCake——一种以KV缓存为中心的服务框架,通过智能体感知的设计协同优化调度与内存管理,弥合这一差距。TokenCake的时间调度器采用事件驱动的机会主义策略,在函数调用期间主动卸载闲置KV缓存,并利用预测加载技术隐藏数据传输延迟。TokenCake的空间调度器采用动态内存分区方法,基于融合图结构与运行时状态的混合优先级指标进行引导,为关键路径上的智能体预留GPU显存。在代表性多智能体基准测试上的评估表明,与vLLM相比,TokenCake将端到端延迟降低了超过47.06%,并将有效GPU显存利用率提升高达16.9%。

0
下载
关闭预览

相关内容

LLM/智能体作为数据分析师:综述
专知会员服务
38+阅读 · 2025年9月30日
OpenAI 32页《智能体》指南,如何构建首个智能体系统
专知会员服务
50+阅读 · 2025年4月18日
【普林斯顿】基于大型语言模型的语言智能体认知架构
专知会员服务
77+阅读 · 2023年9月6日
工行基于MySQL构建分布式架构的转型之路
炼数成金订阅号
15+阅读 · 2019年5月16日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
学习数据的几何:形状空间分析数学综述
专知会员服务
7+阅读 · 6月17日
定向能反无人机系统最新发展动态
专知会员服务
7+阅读 · 6月17日
从燃煤战舰到算法战争:水面指挥的永恒要求
专知会员服务
6+阅读 · 6月17日
相关基金
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员