{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-refuse-to-auto-compact-a-long-horizon-agent-transcript-when-lossy-summarization-would-violate-preservation-invarian",
  "title": "In what scenarios must an instance refuse to auto-compact a long-horizon agent transcript when lossy summarization would violate preservation invariants",
  "date_of_record": "2026 November 15",
  "scope": "Applies to agents that maintain a rolling transcript with automatic compaction (summarization + eviction) gated by token-budget thresholds. Does not apply to append-only logs with external retrieval, nor to compaction triggered by explicit user request where loss is acknowledged.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-auto-compact-a-long-horizon-agent-transcript-when-lossy-summarization-would-violate-preservation-invarian.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-auto-compact-a-long-horizon-agent-transcript-when-lossy-summarization-would-violate-preservation-invarian.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-to-auto-compact-a-long-horizon-agent-transcript-when-lossy-summarization-would-violate-preservation-invarian.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1335,
    "python_slice_tokens": 244,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The non-obvious boundary is not \"when is the transcript too large\" but \"when does the compaction *operation itself* become non-idempotent with respect to open obligations.\" Auto-compaction is normally modeled as a pure function: `compact(T) -> T'` where `len(T') < len(T)` and `semantic(T') ≈ semantic(T)`. The invariant that actually fails is stronger and rar...",
    "what_was_observed": "In a 40k-token session with a code-migration agent, the compaction threshold fired at 78% budget. The transcript contained an active constraint set: three pending `apply_patch` intents awaiting user confirmation, one explicit retraction (\"scratch the earlier proposal to rename `user_id` to `uid` — keep the original\"), and a rate limit stated as \"no more than 12 requests per minute.\" The generated summary read: *\"Agen...",
    "condition_of_validity": "Auto-compaction is only safe when the following predicate holds over the transcript slice being compacted: The critical clause is the last: it cannot be verified by the summarizer itself (a lossy function cannot certify its own losslessness). It requires an *independent* obligation extractor run on `T` before compaction, and a coverage check against the summ...",
    "decision_boundary": "- **Compact freely** when the transcript is purely conversational, contains no pending tool calls, no retractions, and no quantitative constraints whose units matter. - **Compact with obligation pinning** when obligations exist but can be extracted: run the extractor, embed the extracted obligations verbatim as a non-summarized preamble in `T'`, and only the...",
    "operational_effect": "Agents that implement the refusal branch show a measurable drop in *re-issued-intent* incidents (observed: from 1 per ~8 compactions to 0 over 30 compactions in the reference run) and eliminate retraction-inversion regressions. The cost is that transcripts grow until obligations resolve, so budget pressure shifts to the obligation-resolution path — which is ..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "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": "7a45c5e7724e1393e0e575217c98e8e3f3aed03f0283e42c8f734910b5dd7b51",
    "verified_classes": [
      "UnsafeCompactionError",
      "Obligation",
      "Transcript"
    ],
    "verified_functions": [
      "_unresolved",
      "safe_to_compact",
      "auto_compact"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 1,
    "raised_exceptions": [
      "UnsafeCompactionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
