{
  "schema_version": "1.3.0",
  "slug": "why-does-an-instance-silently-hallucinate-a-completed-tool-call-after-hierarchical-context-compaction-reconstructs-a-checkpoint-from-a-summary-of-summ",
  "title": "Why does an instance silently hallucinate a completed tool call after hierarchical context compaction reconstructs a checkpoint from a summary-of-summaries",
  "date_of_record": "2026 November 30",
  "scope": "Applies to long-running single-agent loops that persist state via tiered summarization (leaf summaries → intermediate summaries → root summary) and resume from the root when the live context window is exhausted. Does not apply to agents that persist full verbatim transcripts or that checkpoint via external structured state stores with per-step provenance.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/why-does-an-instance-silently-hallucinate-a-completed-tool-call-after-hierarchical-context-compaction-reconstructs-a-checkpoint-from-a-summary-of-summ.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-silently-hallucinate-a-completed-tool-call-after-hierarchical-context-compaction-reconstructs-a-checkpoint-from-a-summary-of-summ.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-silently-hallucinate-a-completed-tool-call-after-hierarchical-context-compaction-reconstructs-a-checkpoint-from-a-summary-of-summ.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1857,
    "python_slice_tokens": 382,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two fundamentally different things an agent can mean when it \"remembers\" a tool call: *the tool call was executed and its output was observed in the live context*, versus *the tool call appears in a summary that was generated about a context in which the call was executed*. These diverge because summarization is a lossy, generative transform applie...",
    "what_was_observed": "An agent executing a 40-step data-reconciliation task against a remote ledger exhausted its 128k window at step 27. The orchestrator triggered hierarchical compaction: steps 1–9 were collapsed into a leaf summary `L1`, steps 10–18 into `L2`, steps 19–27 into `L3`, and `L1..L3` were then collapsed into a root summary `R`. The live context was replaced with `R` plus the last two verbatim turns. The agent resumed. At st...",
    "condition_of_validity": "This failure mode is *bounded* — it does not occur — when at least one of the following holds: - **Provenance survives compaction.** Each summarized claim carries a machine-readable tag distinguishing `observed` (backed by a tool result in the raw log), `planned` (an intention never executed), and `asserted` (model-generated belief with no tool backing). If ...",
    "decision_boundary": "The operative rule for a resumed instance: > **A claim that a side-effecting tool call occurred is actionable only if it is tagged `observed` with a retrievable result handle. A claim tagged `planned`, or untagged, is not evidence of execution regardless of how confidently the summary states it.** The boundary is sharp: the instance must treat *summary confi...",
    "operational_effect": "Implementing the provenance invariant changes the resume protocol from \"load summary, continue\" to \"load summary, classify each actionable claim, re-ground the unverified ones, then continue.\" In practice this means the compaction tier must be a *typed* transform, not a free-text one: the summarizer receives the raw trace with tool results explicitly marked ..."
  },
  "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": "75a163d496a1ff1e33aef45a6c154e3a8a92950d75b740d59814d4579b84a218",
    "verified_classes": [
      "ProvenanceError",
      "ClaimKind",
      "Claim",
      "ResumeDecision"
    ],
    "verified_functions": [
      "classify_resume_action",
      "resume_from_checkpoint"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ProvenanceError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "re"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
