Don't Stop Me Now: Embedding Based Scheduling for LLMs
Efficient scheduling is crucial for interactive Large Language Model (LLM) applications, where low request completion time directly impacts user engagement. Size-based scheduling algorithms like Shortest Remaining Process Time (SRPT) aim to reduce average request completion time by leveraging known or estimated request sizes and allowing preemption by incoming jobs with shorter service times. However, two main challenges arise when applying size-based scheduling to LLM systems. First, accurately predicting output lengths from prompts is challenging and often resource-intensive, making it impractical for many systems. As a result, the state-of-the-art LLM systems default to first-come, first-served scheduling, which can lead to head-of-line blocking and reduced system efficiency. Second, preemption introduces extra memory overhead to LLM systems as they must maintain intermediate states for unfinished (preempted) requests. In this paper, we propose TRAIL, a method to obtain output predictions from the target LLM itself. After generating each output token, we recycle the embedding of its internal structure as input for a lightweight classifier that predicts the remaining length for each running request. Using these predictions, we propose a prediction-based SRPT variant with limited preemption designed to account for memory overhead in LLM systems. This variant allows preemption early in request execution when memory consumption is low but restricts preemption as requests approach completion to optimize resource utilization. On the theoretical side, we derive a closed-form formula for this SRPT variant in an M/G/1 queue model, which demonstrates its potential value. In our system, we implement this preemption policy alongside our embedding-based prediction method.
Code (0)
등록된 구현이 없습니다.
Tasks
BlockingLarge Language ModelSchedulingMethods 이 논문이 사용한 방법론
Similar Papers 제목 키워드 기반
The Foundational Capabilities of Large Language Models in Predicting Postoperative Risks Using Clinical Notes
Clinical notes recorded during a patient's perioperative journey holds immense informational value. Advances in large language models (LLMs) offer opportunities for bridging this gap. Using 84,875 pre-operative notes and…
Domain AdaptationMulti-Task LearningWord EmbeddingsDynamic Scheduling of MPI-based Distributed Deep Learning Training Jobs
There is a general trend towards solving problems suited to deep learning with more complex deep learning architectures trained on larger training sets. This requires longer compute times and greater data parallelization…
Deep LearningMathSchedulingThroughput Optimization in Cache-aided Networks: An Opportunistic Probing and Scheduling Approach
This paper addresses the challenges of throughput optimization in wireless cache-aided cooperative networks. We propose an opportunistic cooperative probing and scheduling strategy for efficient content delivery. The str…
DiversitySchedulingOn Safety of Passengers Entering a Bus Rapid Transit System from Scheduled Stops
In this paper, we address the vehicle scheduling problem for improving passenger safety in bus rapid transit systems. Our focus is on passengers waiting at street stops to enter terminal stations. To enhance their safety…
PositionSchedulingSeparated Contrastive Learning for Matching in Cross-domain Recommendation with Curriculum Scheduling
Cross-domain recommendation (CDR) is a task that aims to improve the recommendation performance in a target domain by leveraging the information from source domains. Contrastive learning methods have been widely adopted …
Contrastive LearningRecommendation SystemsRepresentation LearningScheduling+1