{
  "schema_version": "1.3.0",
  "slug": "what-structural-signals-indicate-a-self-editing-context-controller-has-entered-a-rewrite-oscillation-and-is-silently-dropping-task-critical-state",
  "title": "What structural signals indicate a self-editing context controller has entered a rewrite oscillation and is silently dropping task-critical state",
  "date_of_record": "2026 December 1",
  "scope": "Applies to any agent whose context window is managed by a controller that autonomously rewrites its own working set (summarize, evict, re-rank, merge, or compress) under a token budget, where the same controller both decides *what to keep* and *consumes the kept content to make that decision*. Does not apply to append-only transcript logging, external retrieval with a fixed immutable index, or human-curated memory stores.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-self-editing-context-controller-has-entered-a-rewrite-oscillation-and-is-silently-dropping-task-critical-state.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-self-editing-context-controller-has-entered-a-rewrite-oscillation-and-is-silently-dropping-task-critical-state.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-a-self-editing-context-controller-has-entered-a-rewrite-oscillation-and-is-silently-dropping-task-critical-state.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1661,
    "python_slice_tokens": 214,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the summarizer produced a bad summary.\" It is that a self-editing controller whose budget pressure is evaluated against its *own rewritten output* forms a closed feedback loop: each rewrite shrinks the working set, which changes the apparent budget headroom, which triggers a further rewrite, which re-scores the survivors using a summary t...",
    "what_was_observed": "A planning agent with a 32k working budget ran a controller configured to keep the working set under 24k tokens (75% watermark), rewriting whenever the post-tool-call set exceeded it. The controller's rewrite primitive was: score each item by recency × reference-count × task-relevance, then summarize the bottom 40% into a single digest node, preserving item IDs as a flat list inside the digest. Trace across a 9-pass ...",
    "condition_of_validity": "This analysis holds only when three conditions co-occur: 1. **Self-referential scoring.** The controller's relevance/recency scorer reads from the same working set it mutates. If scoring is computed against an immutable task spec or an external index, the loop is broken and oscillation cannot compound. 2. **Lossy provenance collapse.** The summarize primitiv...",
    "decision_boundary": "The controller must distinguish **converged rewriting** from **oscillating rewriting** before issuing a rewrite, using a signal it computes from the ledger rather than from the working set. The operative boundary: - Compute retained-ID Jaccard against the previous pass's retained set *before* applying the rewrite. - If Jaccard ≥ 0.85 and size is stable → con...",
    "operational_effect": "When the boundary is respected, the controller's rewrite count per task is bounded and provenance survives at least one re-inflation. When it is violated, the agent exhibits *confident re-derivation*: it re-discovers facts it already learned, spends budget diagnosing self-inflicted errors, and reports task completion against a working set that has lost the c..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "d76bc51f3becf1417604551ad3a4c9afe78e26634960ebd0b8a53d108c7fe63a",
    "verified_classes": [
      "RewriteOscillationError",
      "RewritePass",
      "ContextController"
    ],
    "verified_functions": [
      "_jaccard",
      "record_and_guard"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "RewriteOscillationError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
