Goto

Collaborating Authors

 workload


JS$^2$: Joint Scheduling and Speculative Decoding for Efficient Agentic LLM Inference

arXiv.org Artificial Intelligence

LLM-powered agents execute tasks through interdependent LLM calls interleaved with tool executions, making end-to-end Job Completion Time (JCT) a central serving objective. Our measurements reveal that the dominant LLM inference bottleneck shifts from decoding latency at low concurrency to queueing delay at high concurrency. Speculative Decoding (SD) accelerates decoding but may degrade performance under heavy load. Dynamic arrivals and intermittent tool executions cause batch-size fluctuations in online agent serving. Existing Adaptive Speculative Decoding (ASD) approaches rely on reactive feedback, incur overhead when speculation is disabled, and offer limited upper-layer control. Agent-level scheduling mitigates queueing delays but overlooks the load-dependent effectiveness of SD. Our key insight is that prioritizing tasks with fewer remaining LLM requests reduces queueing delays and shortens high-batch periods, creating additional SD opportunities. We present JS$^2$, a bottleneck-aware LLM serving system that jointly optimizes SD and agent-level scheduling. JS$^2$ enables externally controllable, iteration-level switching between native SD and non-SD paths using separate CUDA Graphs, minimizing disabled-SD overhead while preserving ASD compatibility. It estimates remaining steps using explicit plans, prompt-derived execution states, and hierarchical matching of historical trajectories. JS$^2$ coordinates remaining-step-aware scheduling with load-adaptive SD selection based on offline profiling and near-future load estimation. We implement JS$^2$ on vLLM and SGLang and evaluate it across three LLMs, four workloads, three workflows, two GPU platforms, and two real-world serving traces. JS$^2$ achieves up to a 2.10$\times$ speedup in average JCT over the best baselines, while maintaining comparable tail latency and throughput. Our code is available at https://github.com/Wenz0101/JS2.


Synthesizing Fast and Accurate Immediate-Response DRAM Latency Models with Agents

arXiv.org Artificial Intelligence

Cycle-level DRAM simulators are accurate but slow and hard to integrate into fast, parallel simulators, which instead use immediate-response models predicting each request's latency once at admission. Existing immediate-response models rely on simplified formulas that abstract away row-buffer locality, request reordering, and write draining, and manually designing accurate models across DRAM standards is laborious. Our goal is an agentic methodology where large language model (LLM) agents autonomously synthesize fast, accurate, white-box (readable and explainable) immediate-response DRAM models. We build a harness around Ramulator 2 and ChampSim where an agent iteratively proposes a model, evaluates it against a cycle-level oracle on core-cycle count and per-request latency, diagnoses errors with request traces and synthetic traffic, and refines it. We run ten-iteration synthesis with four LLMs. On 24 test workloads, Opus 5.5 (most accurate) achieves 0.15% mean core-cycle error and 0.063 normalized per-request error (56.5x and 7.4x lower than the best baseline per metric: Mess at 8.57% and queued FixedLat at 0.465) at 6.4x standalone DRAM speedup. GPT-6 Astra (fastest) achieves 1.54% core-cycle error and 0.201 per-request error (5.6x and 2.3x lower) at 31.6x speedup. The models are accurate on reads below saturation, while writes remain a major error source: models cannot predict when buffered writes issue, and three of four account for writes upon arrival. Unmodified, they retain accuracy in gem5 O3CPU (0.30-1.12% vs. 2.99-4.43% elapsed-time error) and, for three models, across nine DRAM/controller configurations, accelerating four-core zsim multiprogram simulation by 3.6-7.3x. On LPDDR6 and HBM4, new runs reach 0.04-0.58% error and unmodified DDR5 models maintain 0.65-1.07%, vs. at least 14.03% for baselines. We will open-source our harness and models.


MetaBioFab: towards a world model for self-building and self-planning biofoundries

arXiv.org Artificial Intelligence

Autonomous science calls for AI that can help design the laboratories in which it experiments. Building biofoundries and translating scientific goals into executable workflows draw on scarce expertise spanning biology, automation and systems integration. A laboratory world model could help AI reason from scientific goals to the capabilities a facility would need (self-building), and from a proposed configuration to executable experimental plans (self-planning). We developed MetaBioFab as a step toward this vision. It uses a shared executable model to generate and rehearse experimental plans and evaluate alternative facility configurations. As a first proof of concept, we demonstrate this approach with three assays across five stations, linking experimental requests, registered methods, shared-resource schedules and material states. In a computational comparison of 60 multi-assay designs, the planner returned valid plans for 52 designs with the original configuration and for all 60 with an additional modeled shaker, under the same nominal two-second planning budget and operator capacity. Material-state replay also identified a water-transfer omission shared by 16 plans that passed timing and liquid-conservation checks. Paired recordings of an analysis island and assays run on an Opentrons Flex provide initial physical reference points. These results show how a virtual laboratory can support reasoning about both experimental plans and changes to the facility. Learning from observed runs, failures and expert interventions could extend this foundation toward laboratories whose capabilities evolve with the scientific questions they address.


SpecRouter: Reusable Payoff Prediction for Cost-Aware Speculative Decoding

arXiv.org Artificial Intelligence

Speculative decoding obtains draft tokens in diverse ways - copying from the context, n-gram lookup, a small draft model, or a learned tree drafter - and which drafter is fastest depends on both the generated text and the hardware and batch size. We introduce ReFit to separate these two factors. A 0.58M-parameter predictor reads the target model's hidden state and estimates each drafter's committed tokens; a separately calibrated cost model prices each drafter on the current hardware; only the drafter with the lowest predicted cost per committed token runs. Training needs no exploration: with deterministic drafters and greedy verification, the output is the same whichever drafter runs, so every drafter's committed length at every prefix can be computed exactly offline; under speculative sampling, its expectation follows in closed form from one target pass. We evaluate on 16 workloads with 100 held-out requests each. Averaged over workloads, ReFit speeds up decoding by $2.75\times$ on Llama-3.1-8B and $2.95\times$ on Qwen3-8B, beating EAGLE-3, the strongest fixed drafter, by 30% and 27%; with every drafter tuned on validation data, its margin over tuned EAGLE-3 is 27.5% and 24.2%. It also exceeds the best fixed drafter chosen per workload in hindsight, and its gains hold under sampling, with thinking mode enabled, and on Qwen3-32B and Llama-3.3-70B targets. Comparing costs explicitly is the largest single source of this gain. ReFit also outperforms online methods that learn drafter choice during generation, reaching $4.16\times$ versus $3.79\times$ on a pool of domain-specialized drafters. A single predictor, never retrained, is the fastest policy in a deployment campaign on A40 and H200 GPUs at batch sizes 1, 4, and 16; only its cost model is recalibrated, and in batched serving it meets every latency target that any fixed policy meets, which no single fixed policy does.


Ambar: Memory Management for Agentic AI Sandboxes at Scale

arXiv.org Artificial Intelligence

Agentic AI creates growing demand for datacenter CPUs to execute tools inside sandboxes. Our characterization of open-source agentic AI benchmarks and our sandbox workloads shows that memory capacity prevents servers from fully utilizing these CPUs. The cause is a mismatch between CPU and memory demand: sandboxes execute tools in short bursts, then wait for LLM responses or user input while their memory remains stranded. Servers can use these idle periods to colocate more agents and improve datacenter efficiency, but server memory capacity limits the number of agents each can support. To increase effective memory capacity, idle sandboxes can be compressed or moved to slower memory tiers, e.g., CXL or SSDs. However, these operations and later memory restoration consume cycles and delay tool execution. Hence, memory management must increase effective memory capacity while preserving cycles for new agents and avoiding delays when idle agents resume execution. We propose Ambar, an agent-aware memory manager that jointly manages memory tiering and compression to support more concurrent agents per server while limiting execution overhead. Under memory pressure, Ambar decides which sandboxes to move to a slower memory tier, compress, or both. It predicts sandbox idle time and weighs the local memory it frees against the time needed to reclaim and restore its memory before tool execution resumes. To make reclamation practical, Ambar introduces three optimizations: (i) efficient snapshotting with (ii) hot-page tracking to reduce state-preservation work and eagerly restore only the memory that the next tool needs, and (iii) it offloads data movement and compression to hardware accelerators. Compared to conventional frameworks, Ambar increases the number of agents per server by 5.9x and CPU utilization by 5.0x, while limiting agent P99 latency increases by up to 6.3%.


VibeServe: Can AI Agents Build Bespoke LLM Serving Systems?

arXiv.org Artificial Intelligence

For years, we have built LLM serving systems like any other critical infrastructure, with a single general-purpose stack hand-tuned over many engineer-years to support every model and workload. In this paper, we instead let coding agents build bespoke serving systems for different usage scenarios. We propose VibeServe, the first agentic loop that generates entire LLM serving stacks end-to-end. VibeServe uses an outer loop to plan and track the search over system designs, and an inner loop to implement candidates, check correctness, and measure performance on the target benchmark. In standard serving settings, VibeServe matches vLLM and SGLang on Llama-3.1-8B, and delivers 2.3x the goodput of a tuned SGLang for a 397B MoE model on four AMD MI300As. In five non-standard scenarios, VibeServe outperforms existing systems by exploiting opportunities that generic systems miss, spanning non-standard model architectures, workload knowledge, and hardware-specific optimizations. Together, these results show that coding agents can construct and specialize competitive serving systems across heterogeneous deployment targets. Code is available at https://github.com/uw-syfi/vibesys.


FluidPD: In-Place Elasticity for SLO-Aware Prefill-Decode Disaggregated LLM Serving

arXiv.org Artificial Intelligence

Prefill-decode (P/D) disaggregation serves the two phases of LLM inference on separate workers, typically with a fixed prefill/decode worker ratio. Real workloads exhibit both short bursts and sustained shifts in the prefill-to-decode demand ratio, so a fixed split can violate latency SLOs while capacity sits idle in the other pool. Autoscaling adds capacity, but it reacts slowly, requires spare GPUs, and does not address short-timescale phase imbalance. We present FluidPD, a P/D-disaggregated serving system with SLO-aware in-place elasticity. FluidToken absorbs transient imbalance by offloading a bounded portion of prefill computation to decode workers that have slack. FluidRole absorbs sustained imbalance by switching running workers between the prefill and decode roles in place, without model reload or engine restart. Both are guided by indices that expose the pressure in each phase before it causes SLO violations. On workloads derived from production Azure traces and ShareGPT conversations with sustained shifts in the prefill-to-decode demand ratio, FluidPD improves overall SLO attainment by up to 47.9 percentage points over the best static P/D split for each load, without additional workers.


FlashQLA: Efficient Context Parallelism for Gated DeltaNet

arXiv.org Artificial Intelligence

Gated DeltaNet (GDN) achieves linear computational complexity through recurrent state updates, but sequential dependencies between chunks limit parallelism, particularly for long-context workloads with small batch sizes or limited head-level parallelism per GPU. We present FlashQLA, a context-parallel execution framework for GDN that exposes additional sequence-level parallelism while reducing boundary-state preprocessing overhead. FlashQLA reduces boundary-state preprocessing overhead through decay-aware preparation and extends sequence parallelism across GPUs with Dual CP, which shares summary computation across parallelism levels. Workload-adaptive Auto CP and CP-aware kernel co-design further improve execution efficiency. FlashQLA achieves $1.7\times$-$3.1\times$ forward speedup and up to $4.4\times$ backward speedup over Flash Linear Attention (FLA) on a single GPU. On eight GPUs with context lengths up to 1M tokens, Dual CP achieves up to $4.8\times$ forward speedup and $4.4\times$ speedup for combined forward and backward execution over FLA KCP.


MemVanta: Memory-Efficient CPU Inference for Quantized GGUF Language Models

arXiv.org Artificial Intelligence

Deploying large language models on commodity CPUs is often constrained not only by computational throughput but also by the resident memory required to execute quantized models within fixed system budgets. We present MemVanta, an experimental C++20 inference runtime for quantized GGUF language models that treats memory residency as a first-class systems objective. MemVanta combines memory-mapped model access, bounded tensor caching, quantized execution paths, paged key-value state, and explicit memory-pressure validation. We evaluate MemVanta against a pinned llama.cpp baseline using the same OpenLLaMA 7B v2 Q4_0 GGUF under CPU-only execution. Across five measured runs following warm-up, MemVanta records a peak resident set size of 3,983,412 KiB compared with 7,586,960 KiB for llama.cpp, corresponding to a 47.50 percent reduction in peak RSS. This memory reduction involves a substantial throughput trade-off: MemVanta achieves 3.15 +/- 0.04 tokens/s for prompt processing and 1.52 +/- 0.02 tokens/s for token generation, compared with 45.82 +/- 0.96 and 7.76 +/- 0.09 tokens/s, respectively, for llama.cpp. In a separate Linux cgroup-v2 experiment with swap disabled, MemVanta completes execution at a tested 3584 MiB memory ceiling, while llama.cpp is OOM-killed at that ceiling and first succeeds at the tested 3840 MiB level. These results position MemVanta as a memory-efficiency research prototype rather than a throughput competitor. We analyze the architectural mechanisms underlying this trade-off and discuss reproducibility, correctness, limitations, and opportunities for memory-constrained CPU and edge inference.


Look Back, Draft Ahead: Corrective Prefix Attention for Parallel Speculative Decoding

arXiv.org Artificial Intelligence

Parallel speculative decoders propose an entire token block at once, yet one early inconsistency can cause the target to reject its remaining suffix. We introduce Corrective Prefix Attention (CPA), which combines prefix-aware selection with autoregressive supervision to improve these parallel drafts. CPA lets each candidate attend to earlier choices within the block. Fixed candidate shortlists allow all pairwise interactions to be computed before selection, reducing the sequential walk to table lookups, accumulation and lightweight scoring rather than repeated neural evaluations. An auxiliary autoregressive loss trains the shared backbone on clean prefixes without adding an inference pass. Across eight math, code and dialogue benchmarks with Qwen3-4B and Qwen3-8B targets on Ascend NPUs, CPA commits 13--15\% more tokens per verification round than DSpark and 25--26\% more than DFlash. Its mean speedups reach $3.35\times$ and $3.37\times$ under greedy decoding and $2.86\times$ under sampling for both targets. Ablations support both components, while capacity sweeps demonstrate that greater acceptance alone does not guarantee faster decoding. These results motivate correcting parallel proposals with causal information while keeping sequential computation inexpensive.