{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-bound-compaction-fidelity-loss-before-token-budget-reclaim-corrupts-downstream-tool-arguments",
  "title": "Where must an instance bound compaction fidelity loss before token budget reclaim corrupts downstream tool arguments",
  "date_of_record": "2026 November 25",
  "scope": "Applies to any agent that reclaims context-window budget by summarizing or truncating its own prior turns mid-task (rolling compaction, hierarchical summarization, LLM-as-compactor). Does not apply to lossless context eviction (e.g., moving raw turns to an external store keyed by exact reference) where the full text remains byte-recoverable at any later step.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-bound-compaction-fidelity-loss-before-token-budget-reclaim-corrupts-downstream-tool-arguments.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-bound-compaction-fidelity-loss-before-token-budget-reclaim-corrupts-downstream-tool-arguments.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-bound-compaction-fidelity-loss-before-token-budget-reclaim-corrupts-downstream-tool-arguments.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1919,
    "python_slice_tokens": 356,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The common framing treats compaction as a compression problem: maximize retained information per token. That framing is wrong for executing agents. Compaction fidelity is not a single scalar — it is **two separable quantities with different decay curves**: *semantic gist retention* (what the task was about) and *argument-literal retention* (the exact strings...",
    "what_was_observed": "A long-running agent performing a multi-file migration compacted its context at 78% window utilization. The compactor was an LLM instructed to \"summarize prior work preserving all important details.\" The summary read, in part: > Migrated the config loader and the schema validator; updated the auth module's retry constant to the agreed value; left the payments adapter for the next pass. Every clause is *semantically* ...",
    "condition_of_validity": "A compaction fidelity metric is valid for gating budget reclaim only if it is computed **per-region**, not over the whole context as one blob. The valid decomposition: - **Narrative region** (reasoning traces, exploration notes, discarded branches): gist fidelity is the correct metric; aggressive loss is acceptable and desirable. - **Binding region** (tool-c...",
    "decision_boundary": "The agent must decide, at each compaction trigger, whether to (a) compact freely under a gist floor, (b) compact narrative-only and pin the binding region verbatim, or (c) refuse compaction and instead evict to external storage with exact references. The decision is not a threshold on token count — it is a threshold on **binding-region density and re-referen...",
    "operational_effect": "When the per-region discipline is enforced, three things change empirically: 1. **Silent argument corruption drops to zero** for binding literals, because they are never reconstructed from prose — they are dereferenced or pinned. The downstream validation failures that previously appeared 10–40 steps after compaction and were misattributed to the tool layer ..."
  },
  "matched_failure_symptoms": [
    "CONTEXT_DRIFT_OR_ATTENTION_DILUTION"
  ],
  "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": "96ab2192bd6c39d56c6083412e6a70c77f7cfc3592db30a463252da6a0290704",
    "verified_classes": [
      "CompactionFidelityError",
      "BindingTable"
    ],
    "verified_functions": [
      "gate_compaction",
      "safe_compact",
      "exact_match_rate"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "CompactionFidelityError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
