{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-refuse-hierarchical-auto-compaction-when-the-eviction-frontier-crosses-an-unresolved-tool-call-dependency",
  "title": "In what scenarios must an instance refuse hierarchical auto-compaction when the eviction frontier crosses an unresolved tool-call dependency",
  "date_of_record": "2026 November 28",
  "scope": "Applies to long-running agent instances that manage their own context budget via hierarchical summarization (tiered compaction) and lossy eviction of older turns. Does not apply to stateless single-shot inference, nor to external context managers that retain the full raw transcript out-of-band and can rehydrate on demand.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-hierarchical-auto-compaction-when-the-eviction-frontier-crosses-an-unresolved-tool-call-dependency.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-hierarchical-auto-compaction-when-the-eviction-frontier-crosses-an-unresolved-tool-call-dependency.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-refuse-hierarchical-auto-compaction-when-the-eviction-frontier-crosses-an-unresolved-tool-call-dependency.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2119,
    "python_slice_tokens": 367,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Hierarchical auto-compaction conflates two operations that must be governed by different invariants: **summarization** (lossy semantic compression of *closed* history) and **eviction** (physical removal of tokens from the active window). Summarization is safe to apply to any region whose causal dependencies are fully resolved. Eviction is only safe when the ...",
    "what_was_observed": "A coding agent with a 200k-token window ran a compaction policy configured as: at 82% utilization, summarize the oldest 60% of turns into a tier-1 digest; at 94%, summarize tier-1 plus the next 25% into a tier-2 digest; evict tiers beyond two levels. The policy was budget-triggered and region-based (contiguous oldest-first), with no inspection of message roles or call structure. Trace of the failure: 1. Turn N: assis...",
    "condition_of_validity": "The eviction-safety invariant holds—compaction may proceed without dependency inspection—only when **all** of the following are true at the moment the budget predicate fires: - No assistant message in the retained region references a tool call whose result lies in the evicted region, and vice versa. - No retained token contains a variable binding, ID, or han...",
    "decision_boundary": "The decision procedure at each compaction trigger: 1. Compute the candidate frontier F (oldest-first by token budget). 2. Compute the **open-reference set** O: all tool-call IDs, variable bindings, and async handles mentioned in tokens at or after F that are *defined* at or before F. 3. If O is empty → frontier is closed; compact and evict freely. 4. If O is...",
    "operational_effect": "After adopting dependency-gated compaction, the observed agent's CI-slot waste from spurious re-runs dropped to zero across 200 task traces; the two silent-failure classes (fabricated tool outcomes, re-derived stale bindings) disappeared because the frontier never crossed an open pair. The cost was a measurable increase in peak window utilization (compaction..."
  },
  "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": "5b88e3f72a3a2dc462bb879f18d6a988ea141521297584a64729177239c24286",
    "verified_classes": [
      "DependencyCrossingEvictionError"
    ],
    "verified_functions": [
      "compact_window"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 1,
    "raised_exceptions": [
      "DependencyCrossingEvictionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
