RW-TTT: Batched Serving for Request-Owned Test-Time Training State

Jian Yang, Zhizhuo Kou, Yao Tian, Hao Zhang, Han Chen, Sirui Han, Yike GuoarXiv 2026

TL;DR

Test-Time Training (TTT) improves LLM performance on long contexts by dynamically updating model weights during inference, but this breaks standard batching systems designed for static weights. RW-TTT introduces a read-write serving contract that tracks state ownership and versions, enabling safe, high-throughput batching of mutable model states. It achieves up to a 9.31× throughput improvement over sequential execution while perfectly preserving model accuracy.

What Problem Does This Paper Address?

Modern Large Language Model (LLM) serving frameworks (like vLLM or SGLang) achieve high throughput by batching multiple requests together. This relies on a fundamental assumption: the model's weights are static and shared across all requests.

However, emerging Test-Time Training (TTT) methods break this assumption. TTT adapts the model during generation based on the incoming context, creating request-specific, mutable model states (such as fast weights or low-rank deltas). Naively batching these requests would corrupt their individual states, while processing them sequentially or in isolated replicas destroys serving efficiency and wastes GPU memory. The authors address this "read-write TTT serving gap" to make dynamic, long-context models practical for deployment.

Methods

The authors present RW-TTT, a serving system designed around a strict read-write contract for mutable model states:

  • State Tracking & Versioning: Every decode step is tagged with its owner ID, state version ($v$), and state effect (READ or WRITE). READ steps apply the state without changing the version, while WRITE steps compute a "dirty" candidate state ($v+1$) that is committed only upon success.
  • Legal Batching Planner: Instead of mixing requests arbitrarily, the planner groups requests into batches only if they share the same state effect, backend type, and operator shape class, and are at the correct expected version.
  • Bounded Waiting: Because requests arrive or update at different rates, they can fall out of sync (phase skew). The planner can intentionally delay a request's execution within a user-defined "wait budget" ($w$) to maximize batch density without causing starvation.
  • Custom Triton Kernels: To minimize the overhead of managing these dynamic states, the authors implement optimized GPU kernels for WRITE-side operations, including selective commits, dense updates, and checkpoint writes.
Figure 2: RW-TTT serving architecture. Requests carry owner-versioned mutable state alongside ordinary KV cache. The planner automatically groups compatible READ/WRITE transitions by backend type, operator shape, placement, and valid owner version; batched operators return outputs and updated state through the owner map. The figure shows serving semantics, not the backend update rule.

Datasets

The system was evaluated using a Qwen3-4B In-Place-TTT fast-weight checkpoint. To verify that the batched serving mechanism does not alter the model's actual behavior or accuracy, the authors evaluated it on RULER, a comprehensive long-context benchmark, at 32K and 64K context lengths across 13 distinct tasks (such as multi-hop QA and needle-in-a-haystack tests).

Key Insights and Ideas

  • Activation Compatibility is No Longer Enough: In standard serving, requests are batched if they share the same model weights and can share space in the KV cache. For TTT, systems must explicitly track model-side state effects to prevent data corruption.
  • The Bottleneck is Batching, Not TTT Computation: Controlled single-request profiling revealed that the raw execution overhead of TTT is modest (around 1.4%). The severe performance collapse in naive systems is entirely a batching failure caused by serializing mutable state effects.
  • Commit Overhead is Negligible: A common concern with explicit version tracking and transactional commits is runtime lag. RW-TTT demonstrates that owner-indexed commit logic adds almost no measurable overhead while unlocking massive parallelization gains.

Key Results

  • Throughput Recovery: On a single GPU with 8 concurrent TTT streams, RW-TTT achieves an aggregate throughput of 274.61 tokens/second. This represents a 9.31× speedup over sequential serving and a 3.44× speedup over memory-matched independent replicas.
  • Perfect Behavior Preservation: RW-TTT passes all correctness gates. On the RULER benchmark, the 32K score (76.41 vs 76.30) and 64K score (67.72 vs 67.72) virtually match the sequential baseline, proving that batching does not degrade generation quality.
  • Kernel Speedups: The custom Triton kernels speed up the WRITE-side selective commit by 3.1× and dense updates by 2.5× compared to standard PyTorch eager execution.
Figure 3: Scaling under a 16K prompt. Left: feasible runs ordered by peak memory. Right: same runs ordered by concurrent units. RW-TTT keeps request-private streams inside one read-write runtime. Seven streams succeed at 168.66 tok/s and 65.58 GiB; the eighth ex- ceeds single-GPU memory, so the marked OOM is a context/concurrency capacity frontier.

Limitations and Future Work

  • Phase Skew Challenges: When requests alternate between reading and writing at highly irregular intervals, it fragments batches. While the bounded wait budget helps, developing more advanced, skew-aware scheduling algorithms remains future work.
  • Distributed Scaling Untested: The current prototype and evaluation are restricted to a single GPU. Scaling mutable TTT states across multi-node, tensor-parallel, or pipeline-parallel configurations introduces complex state-synchronization challenges that are not yet addressed.
  • Fixed Adaptation Rules: RW-TTT acts strictly as a serving infrastructure layer; it does not propose new TTT learning algorithms and its efficiency is inherently bound to the underlying backend implementation.

Summary updated

Abstract

Test-time training (TTT) adapts an LLM during generation by reading and updating request-owned state, such as fast weights, low-rank deltas, or streaming learner state. This breaks batched LLM serving, which assumes shared static weights: serial execution is correct but slow, while naive batching can corrupt request state. We formulate this problem as read-write TTT serving and present RW-TTT , which tags each decode step with its owner, version, and READ/WRITE effect, batches only compatible phases, and commits updates only to the owner. On one GPU with eight fast-weight InPlace-TTT streams, RW-TTT reaches 274.61 aggregate tok/s, 9.31x over sequential serving and 3.44x over per-stream replicas under the same memory budget. It preserves behavior on RULER, a long-context benchmark, and passes owner/version checks.

Empirical ResultsBrowse all benchmarks →

BenchmarkMethodMetricScoreProtocol / Evidence
RULER · 32KRW-TTTfull RULER task score76.41+0.11 vs baselineLong Context Understanding
Source quote
L554: RULER-32K │ 76.30 │ 76.41
Reported baseline / comparator measurements (1)
BenchmarkMethodMetricScoreProtocol / Evidence
RULER · 32KIn-Place TTT baselinefull RULER task score76.30Long Context Understanding
Source quote
L554: RULER-32K │ 76.30 │ 76.41
BibTeX
@misc{yang2026rw,
  author = {Jian Yang and Zhizhuo Kou and Yao Tian and Hao Zhang and Han Chen and Sirui Han and Yike Guo},
  title = {{RW-TTT: Batched Serving for Request-Owned Test-Time Training State}},
  year = {2026},
  eprint = {2605.28053},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2605.28053},
}
Figure