arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2504.07347stat.MLcs.LGmath.PR
收藏

面向LLM推理和AI代理的吞吐量最优调度算法

Throughput-Optimal Scheduling Algorithms for LLM Inference and AI Agents

School of Operations Research and Information Engineering, Cornell University(Cornell大学运筹学与信息工程学院);Operations Management, Booth School of Business, University of Chicago(芝加哥大学博斯商学院运营管理系);Decision, Risk and Operations, Columbia Business School, Columbia University(哥伦比亚大学哥伦比亚商学院决策、风险与运营系)

J. G. Dai, Tianze Deng, Yueying Li, Tianyi Peng

AI总结:

本文从排队论角度研究了LLM推理系统的吞吐量优化问题,证明了工作保持调度算法在DAG和Fork-Join路由拓扑中能实现最大吞吐量,并揭示了批量处理网络中K-FCFS调度的流极限框架,评估了Orca和Sarathi-Serve的吞吐量最优性,同时指出批量大小限制和循环路由拓扑对吞吐量的影响。

摘要:

随着大型语言模型(LLM)和AI代理的需求迅速增长,优化高效LLM推理系统变得至关重要。尽管已有大量针对系统级工程的努力,但从数学建模和排队视角进行探索的却很少。本文开发了LLM推理的排队基础。特别地,我们研究了LLM推理系统的吞吐量方面。我们证明了一类广泛的'工作保持'调度算法在单个请求和AI代理工作负载中都能实现最大吞吐量,建立了'工作保持'作为从业者的关键设计原则。技术上,我们开发了在K-FCFS调度下的多类批量处理网络的流极限框架,这可能具有独立价值。对实际系统的评估证实Orca和Sarathi-Serve是吞吐量最优的,使从业者放心,而FasterTransformer和原生vLLM则不是最大稳定,应谨慎使用。我们的分析还揭示了诸如批量大小限制和循环路由拓扑等约束如何复杂化吞吐量的图景,指向排队论与LLM系统设计交汇处丰富的开放问题。

英文摘要:

As demand for Large Language Models (LLMs) and AI agents grows rapidly, optimizing systems for efficient LLM inference becomes critical. While significant efforts have targeted system-level engineering, little has been explored from a mathematical modeling and queueing perspective. In this paper, we develop the queueing fundamentals for LLM inference. In particular, we study the throughput aspect of LLM inference systems. We prove that a large class of `work-conserving' scheduling algorithms achieve maximum throughput for both individual requests and AI-agent workloads with directed acyclic graph (DAG) and fork-join routing topologies, establishing `work-conserving' as a key design principle for practitioners. Technically, we develop a fluid-limit framework for multi-class batched processing networks under $K$-FCFS scheduling, which may be of independent interest. Evaluations of real-world systems confirm that Orca and Sarathi-Serve are throughput-optimal, reassuring practitioners, while FasterTransformer and vanilla vLLM are not maximally stable and should be used with caution. Our analysis also reveals how constraints such as batch size limits and cyclic routing topologies complicate the throughput picture, pointing to rich open questions at the intersection of queueing theory and LLM system design.

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

↑