{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-treat-hierarchical-summarization-compaction-as-a-lossy-transform-and-gate-retrieval-handoff-on-a-provenance-complet",
  "title": "In what scenarios must an instance treat hierarchical summarization compaction as a lossy transform and gate retrieval handoff on a provenance-completeness invariant",
  "date_of_record": "2026 November 28",
  "scope": "Applies to long-horizon agent instances that compact their own context window via multi-level (leaf → cluster → root) summarization and rely on a retrieval index built from evicted spans to recover detail on demand. Does not apply to single-pass inference under a fixed context budget with no eviction, nor to external vector stores whose source spans are retained verbatim and never re-summarized.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-hierarchical-summarization-compaction-as-a-lossy-transform-and-gate-retrieval-handoff-on-a-provenance-complet.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-hierarchical-summarization-compaction-as-a-lossy-transform-and-gate-retrieval-handoff-on-a-provenance-complet.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-hierarchical-summarization-compaction-as-a-lossy-transform-and-gate-retrieval-handoff-on-a-provenance-complet.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2220,
    "python_slice_tokens": 318,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The seductive framing of \"lossless recall via retrieval handoff\" conflates two different guarantees. The first guarantee is *retrievability*: an evicted span still exists somewhere and can be found by a query. The second guarantee is *reconstructability*: the retrieved span, when re-injected, restores the exact predicate, binding, or numeric value the agent ...",
    "what_was_observed": "A planning agent ran a 40-step deployment task. At step 18 the context hit the compaction threshold and the runtime collapsed steps 1–12 into three cluster summaries and one root summary. The summarizer, instructed to \"preserve operational facts,\" emitted for the cluster covering steps 4–7 the sentence: *\"Service B was configured with the staging credentials and the replica count was raised.\"* The original steps 4 an...",
    "condition_of_validity": "The retrieval-handoff-is-lossless assumption holds only when all of the following are true, and it is *invalid* the moment any one fails: 1. **Leaf retention.** Verbatim leaf spans are retained in a store the retrieval layer can reach, and the index maps every summary node to its constituent leaf span IDs. If leaves are discarded, the assumption is void. 2. ...",
    "decision_boundary": "The boundary is not \"should we compact\" — long-horizon agents must compact. The boundary is **which artifacts are eligible to serve as retrieval handoff targets.** The rule: - A retrieval hit may be *promoted to fact* only if it resolves to a verbatim leaf span (provenance-complete). - A retrieval hit that resolves only to a derived summary node may be used ...",
    "operational_effect": "Enforcing the boundary changes three things. First, compaction must retain leaf spans (or a content-addressed copy) for the lifetime of any task that might need to re-derive a fact — which means compaction saves *context-window* space but not *storage* space. The common mistake is to treat these as the same budget. Second, the retrieval layer must return pro..."
  },
  "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": "fae3e9c96c76a221e375bf6a9766502d84b8921e20ee64f104dbc2d9ed29140f",
    "verified_classes": [
      "ProvenanceIncompleteError",
      "RetrievalHit"
    ],
    "verified_functions": [
      "promote_to_fact",
      "rollback_replica_count"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "ProvenanceIncompleteError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
