arXiv paper· LLM agent systems (systems/infrastructure for machine learning)· method paper

ContextPipe: Database-Inspired Context Assembly for Long-Horizon Agents

Peng Xu, Zuyu Zhang, Yuze Sun, Feng Tian, Long Wang, Chen Zhang

cs.AI · cs.DB

Quick verdict

ContextPipe recasts LLM context assembly as DB query execution; elegant design, but evidence is just 3 SWE-bench Pro instances with no quality metrics.

Summary

The paper argues that context assembly in long-horizon LLM agents — deciding what enters each prompt, in what order, and when to compact history under a hard context-window budget and a byte-sensitive prefix cache — is structurally isomorphic to relational query execution. ContextPipe operationalizes the analogy as a five-phase pipeline (Plan, Bind, Optimize, Execute, Feedback), an eight-tier lifecycle catalog (ContextSources, introducing SessionLatches and EmergentContext), a deterministic cache-aware optimizer that sorts sections by ascending volatility and applies tier-gated compaction, and an EXPLAIN ANALYZE trace recording every applied or skipped transformation. On the SWE-bench Pro Qutebrowser subset (3 of 79 instances, three repeats, DeepSeek-V4-Pro), Structured versus the Flat append-only baseline cut total prompt tokens 30.1% (1,045,222 to 730,978), with Table 4 reporting 17.2% fewer LLM calls and 7.8% shorter runs while the prose claims 23.1% and 8.7%; fresh tokens more than doubled and cache-hit rate fell from 95.3% to 86.2%. The authors derive a billed-cost break-even at cached-price ratio 0.145, conceding the baseline is about 11% cheaper at DeepSeek-like pricing. Key limitations: nine runs per condition with no statistical tests or variance, a declared resolve-rate metric never numerically reported, a single in-house baseline with ablations A1-A4 deferred, and no code release.

Review complete

Assessment at a glance

LLM agent systems (systems/infrastructure for machine learning)

5

risk flags identified

● high 1

● medium 3

● low 1

Reproducibility readinesslow
Code & data availablenot stated
Review confidencehigh
AI text signal0/20 passages flagged
Deep research viable

4 strengths · 5 weaknesses · 5 author questions

AI text signal = Binoculars zero-shot detector score over 20 sampled passages (Fast-DetectGPT co-reported) — absence does not prove human authorship, and a flag does not imply misconduct.

Levels reflect verification complexity — not a quality score. Evolve never rates your paper.

Key claims under review

  • Context assembly in long-horizon LLM agents is structurally isomorphic to relational query execution and should be organized as a five-phase Plan-Bind-Optimize-Execute-Feedback pipeline with a lifecycle catalog and an EXPLAIN ANALYZE trace (Sections 1-2).
  • A deterministic, cache-aware policy — ascending-volatility placement plus tier-gated compaction with logged skips — makes context assembly auditable, replayable, and failure-isolated (Properties 1-3, Section 3.7).
  • On the SWE-bench Pro Qutebrowser subset with DeepSeek-V4-Pro, Structured reduces total prompt tokens 30.1% versus append-only Flat, with fewer LLM calls and shorter runs per Table 4 (17.2% and 7.8%), at the cost of more-than-doubled fresh tokens and a cache-hit rate falling from 95.3% to 86.2%.
  • The billed-cost tradeoff has a break-even at cached-token price ratio 0.145, so neither policy is unconditionally cheaper — the winner depends on provider pricing.

Strengths

  • The database analogy is load-bearing, not decorative

    The isomorphism is given operational content: five phases with typed inputs/outputs and purity constraints (Section 2), a catalog record schema mirroring information_schema (Table 2), a stage-to-optimizer-state mapping that makes each phase unit-testable (Table 3), and Selinger-style percentile statistics (Section 3.8).

  • Determinism and auditability are engineered in, and demonstrated

    Algorithm 1 records every applied and skipped transform; Table 5's real trace shows each compaction-tier crossing as an attributable one-call cache break (8% at call 13 TrimSchemas, 11% at call 24 CompactHistory) with immediate recovery to 93-100%, exactly the diagnosis workflow the trace is designed for.

  • Honest cost accounting of its own tradeoff

  • Conservative, defensive mechanism design

Weaknesses

  • Evaluation far too small for the headline claims

  • Prose contradicts Table 4

  • Quality metric declared but never quantified

  • Single in-house baseline, all ablations deferred

  • No artifact release; verification impossible

Full Review Report

$1.99 · one-time

Unlock the complete preliminary analysis Evolve produced for this paper.

Report preview

ContextPipe: Database-Inspired Context Assembly for Long-Horizon Agents — Preliminary Review

The remaining sections cover Methodology Assessment, Statistical Evidence, Results & Reproducibility, Limitations & Risks, and Verdict & Recommendations.

  • All 4 strengths & 5 weaknesses, analyzed in detail
  • 5 risk flags with severity, section & reviewer questions
  • Methods & statistical evidence assessment
  • 5 questions a peer reviewer would ask
  • Full six-dimension evaluation report & recommendations

One-time purchase · this paper only

One-time purchase, this paper only. AI-generated preliminary analysis — not peer review.

Frequently asked questions

What is ContextPipe?

ContextPipe is a runtime that assembles LLM agent prompts the way a database executes queries: a five-phase Plan-Bind-Optimize-Execute-Feedback pipeline backed by a catalog of context sources, a deterministic cache-aware optimizer that decides ordering, compaction, and cache-marker placement, and an EXPLAIN ANALYZE-style trace recording every decision for each model call.

What results does the ContextPipe paper report?

On 3 instances (3 repeats each) of the SWE-bench Pro Qutebrowser subset with DeepSeek-V4-Pro, ContextPipe (Structured) cut total prompt tokens 30.1% versus an append-only baseline (Flat), with fewer LLM calls and faster runs (Table 4: 17.2% and 7.8%; the paper's text says 23.1% and 8.7%), but uncached tokens more than doubled and cache-hit rate fell from 95.3% to 86.2%.

Does ContextPipe actually save money?

Not always. Because each compaction breaks the cached prefix, ContextPipe's billed cost is lower only where cached tokens cost more than about 14.5% of fresh tokens; at DeepSeek-like pricing (ratio about 0.1) the paper concedes the append-only baseline is roughly 11% cheaper despite sending 43% more total context.

Is code available for ContextPipe and is the evaluation reliable?

The paper announces no public code or artifact release. The evaluation is explicitly preliminary: 3 of 79 subset instances, three repeats, per-cell means, no statistical tests or variance, a resolve-rate metric declared but never numerically reported, and all four mechanism ablations deferred to future work.

About this review

This is an AI-generated preliminary review by Evolve.Pub, produced from the openly available text of the paper. It is not peer review and does not represent the authors' views. The canonical record of the paper is at the publisher link above.

  • Tables and the Figure 1/2 diagrams were extracted as flattened text; all numeric content was legible, and the document is complete through reference [30] — no truncation observed.

Go deeper on this paper

Reproduce ResultsNot feasible for this paper — the core results cannot be re-derived by sandboxed code simulation.

Wrote a paper? Stress-test it before reviewers do.

Upload your manuscript for the same structured scrutiny — reasoning, statistics, evidence, figures, and reproducibility.

Scan your paper
ContextPipe: Database-Inspired Context Assembly for Long-Horizon Agents | Evolve.Pub