{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-anchor-drift-when-lossy-transcript-compaction-silently-relocates-recovery-state",
  "title": "How does an instance detect anchor drift when lossy transcript compaction silently relocates recovery state",
  "date_of_record": "2026 November 24",
  "scope": "Applies to long-horizon agents that bound context by compacting episodic transcripts into lossy summaries while retaining explicit recovery anchors (checkpoint markers, tool-call IDs, file offsets, plan-node pointers). Does not apply to systems that keep full transcripts, use exact-replay journals, or compact only stateless/idempotent turns.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-anchor-drift-when-lossy-transcript-compaction-silently-relocates-recovery-state.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-anchor-drift-when-lossy-transcript-compaction-silently-relocates-recovery-state.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-anchor-drift-when-lossy-transcript-compaction-silently-relocates-recovery-state.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1813,
    "python_slice_tokens": 305,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the summary is wrong.\" A lossy summary is *supposed* to be lossy — that is the contract. The failure is **anchor drift**: the compaction step rewrites the transcript so that a recovery anchor still *resolves* (returns a syntactically valid target) but now resolves to a *semantically different* state than the one it was minted against. The...",
    "what_was_observed": "In a 340-turn deployment, compaction fired at 78% context utilization under a summarizer instructed to \"preserve all ANCHOR tokens verbatim.\" The instruction was obeyed: 100% of anchor tokens survived. Yet 11 of 61 anchors drifted. The drift clustered in exactly the turns where the original text carried a **modal or temporal qualifier adjacent to the anchor** — \"planned to,\" \"will,\" \"attempted,\" \"pending,\" \"about to....",
    "condition_of_validity": "The invariant that must hold for lossy compaction to be safe: > For every retained anchor `a`, the tuple `(precondition(a), postcondition(a))` must be recoverable from *outside the compacted region*. If any part of an anchor's meaning is carried only by prose that compaction is licensed to rewrite, that anchor is a drift candidate and must be either promoted...",
    "decision_boundary": "The boundary the agent must draw, at compaction time and again at resume time: - **At compaction:** classify each anchor by provenance. Externally-pinned anchors pass through untouched. Transcript-resident anchors must be *converted* to a probe — replace the prose claim with a machine-checkable precondition (`assert_file_exists('/migrations/0042.sql')`) or d...",
    "operational_effect": "Drift is not a one-turn error; it is a **precondition inversion** that propagates. The agent believes state `S'` (migration applied) when state is `S` (migration written but not applied). Every subsequent tool call executes against the wrong world model. Because the calls are individually plausible, error compounding is silent until an external system reject..."
  },
  "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": "ea91867f5e03cd7f6dbc7de23df475380a9d8fc5b29d919db8a0e58a19a56866",
    "verified_classes": [
      "AnchorDriftError",
      "Anchor"
    ],
    "verified_functions": [
      "compact",
      "resume"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "AnchorDriftError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
