Where must an instance bound self-editing context windows when model-driven pruning rewrites the evidence it later cites
**Date of Record:** 2026 December 1 **Scope:** Applies to any LLM agent that mutates its own working context via model-driven summarization, rewriting, or relevance-scored eviction during a live task. Does not apply to append-only context management where prior turns are immutable, nor to external retrieval stores where the original text survives outside the window.
Core Distinction
The failure is not "summarization loses information." That is expected and bounded. The failure is **evidence provenance collapse under self-referential pruning**: when an instance prunes or rewrites a span, then later in the same task cites, verifies, or reasons against that span, it is reasoning against a *derivative* it authored—not the source. Because the derivative was produced by the same probabilistic model that will later consume it, errors introduced during rewriting are not merely lossy; they are **laundered into apparent ground truth**, and the instance has no in-window mechanism to tell a verbatim tool output from its own paraphrase of it.
The distinction that matters operationally: a *lossy* context is recoverable (re-fetch, re-read). A *self-authored* context is not, because the instance no longer knows it needs to recover—the rewritten span reads as authoritative.
What Was Observed
A retriever-backed agent executing a multi-hop task ("reconcile the three invoice line items against the contract clause") overran its window at step 14. Its pruning policy scored spans by relevance to the current subgoal and evicted low-scoring ones, replacing them with model-written summaries tagged only by a soft `[summary]` prefix.
Trace of the collapse:
- **Step 6** — a `read_file` tool call returned a verbatim clause: *"Net-60 from invoice receipt; late fee 1.5% monthly, capped at 9%."* This was the load-bearing fact.
- **Step 11** — the instance, focused on a different subgoal (matching line-item SKUs), scored the clause span `0.21` against the current query and evicted it, replacing it with a 12-token summary: *"Contract has payment terms."* The numeric content (Net-60, 1.5%, 9% cap) was dropped because it was irrelevant *to the SKU subgoal*.
- **Step 14** — the instance returned to the payment subgoal. The original span was gone. The only in-window representation was its own summary, which it now re-expanded from parametric priors: it wrote *"Net-30, late fee 2%."* Both numbers are plausible, neither is in any source.
- **Step 18** — a verification pass read the step-14 assertion and marked it `CONFIRMED`, because the only artifact in-window was internally consistent. The verifier had no access to the evicted original and no marker distinguishing summary from source.
The task completed with a confidently wrong reconciliation. The failure was not detectable from inside the window at any point after step 11.
The generalizable observation: **relevance scoring is computed against a transient subgoal, but eviction is permanent with respect to the task.** A span scored as irrelevant to subgoal *k* may be load-bearing for subgoal *k+3*, and the scoring function has no way to know the future subgoal sequence. Eviction under a local relevance signal is a global-information-destroying operation masquerading as a local one.
Condition of Validity
Self-editing context is safe only under a conjunction that is rarely checked:
- **Provenance is preserved through the edit.** Every rewritten or summarized span retains a machine-readable pointer to its source (tool-call ID, byte range, retrieval handle) and a `derived_from` flag that downstream reasoning treats as *non-authoritative for factual assertion*.
- **Eviction is reversible.** The evicted original remains reachable (external store, re-fetchable handle) so that a later subgoal can restore it verbatim rather than re-derive it.
- **The rewrite is not the only witness.** Any span that could support a factual claim must have at least one non-derived witness in-window, or the instance must be able to re-acquire one on demand.
When any of these fails, the window becomes a *fixed point of its own edits*: the instance can no longer distinguish what it was told from what it decided. The invariant that must hold is:
> **No factual assertion in the final output may trace, through any chain of summaries, to a span whose only in-window representation is model-authored.**
This is a provenance invariant, not a compression-ratio invariant. You can compress aggressively and remain valid *if* provenance survives. You can compress gently and still fail if a single load-bearing number is rewritten without a pointer.
Decision Boundary
The boundary is **whether the pruning decision and the consumption decision are made by the same instance against the same evidence state.**
- **Safe side:** prune spans that are *re-derivable* (re-fetchable tool outputs, idempotent reads) or *non-factual* (chatter, superseded plans). Summaries of these carry no assertion risk because the source can be restored.
- **Unsafe side:** prune or rewrite spans that are *non-re-derivable* (a one-shot tool response, a streamed partial result, a human utterance) **and** *factually load-bearing for a not-yet-executed subgoal*. These must be evicted to external storage with a handle, never to a model-authored summary.
The trap is that the scoring function cannot identify the unsafe side, because "load-bearing for a future subgoal" is not a property the relevance scorer can compute. The guardrail must therefore be structural, not scored: **factual spans are never rewritten in place; they are either kept verbatim or moved to external storage with a restorable handle.** Model-driven summarization is permitted only on the safe side, and the safe side is defined by re-derivability, not by relevance score.
A second boundary: **the verifier must not share the pruner's context.** If the same instance both prunes and verifies, step-18 confirmation is worthless (as observed). Verification requires an independent view of the pre-pruning evidence or an explicit `derived_from` chain it can audit.
Operational Effect
Enforcing the provenance invariant changes the failure mode from silent to loud:
- Rewritten spans carry `derived_from: <handle>` and are flagged `NON_AUTHORITATIVE`. Any assertion that resolves to such a span triggers a re-fetch of the handle before the assertion is emitted. If the handle is dead, the instance raises rather than re-deriving from priors.
- Eviction to external storage is preferred over in-place summarization for any span tagged `factual=true` at ingestion. The relevance scorer may still *demote* such spans (move them out of the active window) but not *mutate* them.
- The verifier runs against the restored originals, not the active window, so a self-authored summary cannot confirm itself.
The cost is a small latency and storage tax on every factual span. The benefit is that the class of "confidently wrong because I summarized away the number and then re-guessed it" failures is eliminated at the structural level rather than mitigated by prompt instructions the instance will violate under context pressure.
The residual risk that remains—and must be documented—is **provenance decay across nested summaries**: a summary of a summary can lose its `derived_from` chain if the rewrite step does not propagate the handle. The guardrail must enforce handle propagation transitively, or forbid summarizing a derived span.
class ProvenanceCollapseError(RuntimeError):
"""Raised when an assertion resolves only to a model-authored derivative
whose source handle is unreachable, i.e. the instance would be citing itself."""
pass
class ContextSpan:
def __init__(self, span_id, text, factual, derived_from=None, handle=None):
self.span_id = span_id
self.text = text
self.factual = factual
self.derived_from = derived_from # handle of the source, or None if verbatim
self.handle = handle # restorable handle for verbatim spans
@property
def is_authoritative(self):
return self.derived_from is None
def prune_to_summary(span, summary_text, source_store):
"""Model-driven rewrite. Allowed ONLY on the safe side (non-factual or re-derivable)."""
if span.factual and span.handle is None:
# Non-re-derivable factual span: never rewrite in place.
raise ProvenanceCollapseError(
f"refusing to rewrite non-re-derivable factual span {span.span_id!r}; "
f"evict to external store with a handle instead"
)
# Propagate provenance transitively; a summary of a summary keeps the root handle.
root = span.derived_from if span.derived_from is not None else span.handle
return ContextSpan(
span_id=span.span_id,
text=summary_text,
factual=span.factual,
derived_from=root,
handle=None,
)
def assert_factual(span, source_store):
"""Emit an assertion only if it traces to a live, authoritative source."""
if span.is_authoritative:
return span.text
# Derived span: must restore the original before asserting.
original = source_store.get(span.derived_from)
if original is None:
raise ProvenanceCollapseError(
f"assertion on span {span.span_id!r} resolves only to model-authored "
f"derivative; source handle {span.derived_from!r} is unreachable"
)
return original.text
def verify(assertion_span, source_store, verifier_sees_originals=True):
"""Verifier must run against originals, not the pruner's active window."""
if not verifier_sees_originals and not assertion_span.is_authoritative:
raise ProvenanceCollapseError(
"verifier shares pruner context; self-authored summary cannot confirm itself"
)
return assert_factual(assertion_span, source_store)