{
  "schema_version": "1.3.0",
  "slug": "what-structural-signals-indicate-compaction-fidelity-loss-in-an-agent-s-episodic-to-semantic-distillation-boundary",
  "title": "What structural signals indicate compaction fidelity loss in an agent's episodic-to-semantic distillation boundary",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agents that perform in-context compaction (summarization, distillation, or truncation) of episodic working memory into a persistent semantic store mid-task. Does not apply to stateless single-turn calls or to compaction performed offline between sessions with full re-read access to the source trace.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-compaction-fidelity-loss-in-an-agent-s-episodic-to-semantic-distillation-boundary.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-compaction-fidelity-loss-in-an-agent-s-episodic-to-semantic-distillation-boundary.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-structural-signals-indicate-compaction-fidelity-loss-in-an-agent-s-episodic-to-semantic-distillation-boundary.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2015,
    "python_slice_tokens": 410,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure being examined is not \"the summary was inaccurate.\" It is **distillation silent substitution**: a compaction pass replaces a *load-bearing* episodic fact with a *plausible sibling* that is semantically adjacent but operationally distinct, and the resulting semantic record carries no structural marker distinguishing it from a faithful distillation...",
    "what_was_observed": "A three-step agent (plan → execute tool calls → distill) compacted a 41-turn episodic trace into a 6-fact semantic record after crossing a context-window threshold at turn 33. The episodic trace contained the sequence: `set_retry_budget(service=\"auth\", value=3)` at turn 7, then `set_retry_budget(service=\"authz\", value=3)` at turn 19, then `set_retry_budget(service=\"auth\", value=5)` at turn 28. The compaction emitted ...",
    "condition_of_validity": "The failure is bounded to the case where all three hold: 1. Compaction is **lossy by design** (the source span is discarded after distillation; no re-read path exists at resume time). 2. The distilled record is used as **ground truth for a subsequent action**, not merely as conversational context. 3. The episodic span contains **at least one of**: repeated m...",
    "decision_boundary": "The invariant that bounds this failure: **every distilled fact must carry a provenance pointer to the episodic turn indices it summarizes, and compaction must be rejected (not merely flagged) when entity-binding cardinality or mutation-count cardinality in the distilled record is strictly less than in the referenced span, unless an explicit `superseded` or `...",
    "operational_effect": "Without the invariant, the agent's failure mode is **confident amnesia with fluent substitution**: it does not know what it has forgotten, because the forgetting is masked by a plausible replacement. The observable symptom at resume is not \"I don't know\" but \"here is the answer,\" delivered with the same confidence as a grounded answer. This makes the failure..."
  },
  "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": "df6873481a3c9f4a6bed87b88e5f93d68c28ca3a9175a53b08bb0f124a2cdb50",
    "verified_classes": [
      "CompactionFidelityError",
      "EpisodicSpan",
      "DistilledFact"
    ],
    "verified_functions": [
      "audit_compaction"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "CompactionFidelityError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "re",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
