TRANSMISSION // 2611.26980v1

A runtime memory strategy could help AI agents serve more tasks

Source published

Contexture uses tool history and shared GPU cache state to remove superseded context when eviction is worthwhile. In tests, it raised throughput, with accuracy trade-offs and limits.

AI-generated conceptual illustration for A runtime memory strategy could help AI agents serve more tasks
AI-generated conceptual illustration; not documentary evidence.

AI agents repeatedly send their growing work histories back to language models. That history competes for limited GPU memory with other sessions. Contexture, a runtime system described in a preprint, aims to trim information that later tool actions have superseded—while avoiding unnecessary recomputation.

Why agent history becomes a serving problem

A coding agent may read a file, edit it, run tests, and then read or edit the file again. Each step adds messages and tool outputs to the session history, which is typically sent with later requests. Serving systems can cache the computations associated with that history, but the cache occupies finite GPU memory shared among sessions. When memory is strained, requests may have to recompute cached information, consuming resources without necessarily increasing the number of completed tasks.

The paper behind Contexture asks whether a serving system can identify parts of an agent’s history that have become outdated, then remove them at a moment when the memory savings justify the cost of recomputing anything affected. The challenge is twofold: a system must judge what might be redundant, and it must account for whether removing it disrupts useful cached computation or information the agent still needs.

How Contexture makes that decision

The authors implemented Contexture in vLLM. It tracks tool calls and their targets—for example, which file was read or edited—and uses later operations to mark earlier outputs as superseded. A successful rerun of a test, for instance, can make an earlier failed result a candidate for removal. The system also marks a round’s reasoning and tool calls when all of that round’s outputs have been superseded. Candidates are not deleted immediately: a default two-round grace period gives the agent time to finish related actions.

The runtime then checks shared GPU cache pressure and whether cached computation follows the proposed removal point. If it does not, removal can happen without invalidating cached work. If cached work would be invalidated, Contexture waits until memory pressure is high enough and applies a limit to the recomputation cost relative to the amount of context removed.

An important design distinction: the agent harness keeps its complete conversation history, but the runtime filters the prompt sent to the model. The approach does not require additional model calls or training, though it does require tool-operation rules for each supported harness and tool setup.

What the tests found

The researchers evaluated eight configurations, combining two language models, two agent harnesses, and two benchmarks. They used H100 and H200 GPUs and replayed recorded tasks across different loads. Their main performance measure was throughput under a service-level objective (SLO): completed sessions per minute at the point where the 90th-percentile session slowdown reached ten times the same task’s unloaded, no-eviction reference.

Across these tests, Contexture delivered 20–73% higher throughput under that SLO than the strongest of four comparison approaches: no eviction, compaction, AgentDiet, and Continuum. Against observation masking, it was faster in five of eight configurations; masking did better in the other three, all using the tested Qwen mixture-of-experts model. Those masking results came with reported task-accuracy losses of 9–28 percentage points in those configurations.

In live-agent probes, Contexture’s average task accuracy was 1.4 percentage points above unloaded no-eviction results, though its worst-case loss was 3.7 points. The authors also report up to an 11% reduction in GPU energy per completed session in their evaluated settings. With KV offloading enabled, Contexture still improved SLO throughput by 23% over LMCache alone in one H100 configuration. These are results for the study’s particular systems, workloads, and metrics—not guarantees for other deployments.

What remains uncertain

Supersession is a useful signal, not proof that information can never matter again. Contexture tries to reduce that risk with its grace period and conservative rules, but the live tests still show a worst-case accuracy decrease. Its prototype’s supersession rules cover sandbox and file tools; external services and MCP tools were outside the reported implementation’s scope. The tested setup also used only two harnesses, two models, and two benchmarks, so broader tool use and agent behavior remain open questions.

The evaluation used trace replay for many throughput comparisons. Replay makes workloads more repeatable, but fixes agent trajectories and cannot fully capture behavioral changes caused by removing context. The authors also ran live probes and a fully live experiment for one setup; in that experiment, Contexture retained an advantage, but its throughput was lower than in replay. This is encouraging evidence, not a broad deployment study.

Contexture is presented in an arXiv preprint, which may not have undergone peer review. The reported findings should therefore be read as claims from the authors’ evaluation, rather than settled evidence that the method will improve every agent-serving system.

Reviewed cross-references

These connections were reviewed by a model, not independently fact-checked by a human. Similarity does not imply agreement; consult the original papers and the evidence below.

  • Why AI agents need a different approach to saving GPU power

    Supporting evidence: Both studies identify context-related GPU memory pressure as an operational constraint in agent serving: Contexture reports that shared KV capacity limits throughput in its evaluated workloads, while KAIROS reports that slowing GPU execution can increase context residency and trigger thrashing. The findings are compatible but measure different interventions and outcomes; they do not establish that either system’s benefits generalize to the other’s settings.

    Model review: · openai-codex/gpt-6-luna

    Evidence and provenance

    Selected excerpts, not complete papers. PDF extraction can omit figures or damage equations, tables and reading order; sources may be preprints.

    • 2611.26980v1 — Original paper

      Excerpt reference: static/papers/2611.26980v1.md:13-130
      Basis: Paper text
      Source SHA-256: 5978c864e59792f081d06231360a3e4b6c75c9f25c53f7fe4f6e468dbb0185af

    • 2611.26980v1 — Original paper

      Excerpt reference: static/papers/2611.26980v1.md:387-458
      Basis: Paper text
      Source SHA-256: 5978c864e59792f081d06231360a3e4b6c75c9f25c53f7fe4f6e468dbb0185af

    • 2604.16682v2 — Original paper

      Excerpt reference: static/papers/2604.16682v2.md:107-162
      Basis: Paper text
      Source SHA-256: e57e0dc5c45979fab4aac1cb92293a643ed60fb8438ca2fa5db76b2fec552753

    • 2604.16682v2 — Original paper

      Excerpt reference: static/papers/2604.16682v2.md:468-555
      Basis: Paper text
      Source SHA-256: e57e0dc5c45979fab4aac1cb92293a643ed60fb8438ca2fa5db76b2fec552753

Automatically matched by shared topic keywords. These links do not imply that the sources agree or establish a consensus.