{
  "schema_version": "1.3.0",
  "slug": "in-what-scenarios-must-an-instance-treat-token-budget-eviction-as-a-lossy-checkpoint-rather-than-a-cache-miss",
  "title": "In what scenarios must an instance treat token-budget eviction as a lossy checkpoint rather than a cache miss",
  "date_of_record": "2026 December 2",
  "scope": "Applies to long-horizon agents running under a priority-based context-window scheduler that evicts segments when the token budget is exhausted, where evicted segments are recoverable only via re-derivation from external stores or prior turns. Does not apply to stateless single-turn inference, nor to architectures with unbounded context or lossless external memory keyed by exact content hash.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-token-budget-eviction-as-a-lossy-checkpoint-rather-than-a-cache-miss.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-token-budget-eviction-as-a-lossy-checkpoint-rather-than-a-cache-miss.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/in-what-scenarios-must-an-instance-treat-token-budget-eviction-as-a-lossy-checkpoint-rather-than-a-cache-miss.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1779,
    "python_slice_tokens": 353,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "A priority-based eviction policy is conventionally modeled as a *cache*: the scheduler sorts context segments by a priority score, evicts the lowest-scored segment when the token budget is breached, and assumes that if the segment is needed again it can be \"re-fetched\" cheaply. This mental model is correct only when the evicted segment is *idempotently recon...",
    "what_was_observed": "A 40-step tool-using agent was scheduled under a segment-priority evictor with a hard 96k-token budget. Segments were scored by `priority = recency_weight * age_decay + salience`, where `salience` was assigned at insertion time by a lightweight classifier that rated \"instructional\" and \"user-stated constraint\" content highly and rated \"tool output\" and \"assistant deliberation\" low. At step 27 the budget breached. The...",
    "condition_of_validity": "The cache model is valid **if and only if** every evictable segment satisfies the derivability invariant: > For every segment `s` evicted at time `t`, there exists a deterministic function `reconstruct(s)` over state that survives eviction, such that `reconstruct(s) == s` byte-for-byte or semantically-equivalent under the agent's own equivalence relation. To...",
    "decision_boundary": "The boundary is crossed at the moment the evictor's sort key ranks a non-derivable segment below a derivable one *and* the budget forces a choice between them. Concretely: - If `budget_remaining >= sum(tokens of all non-derivable segments)`, evict derivable segments only; the cache model holds. - If `budget_remaining < sum(tokens of all non-derivable segment...",
    "operational_effect": "Under the correct protocol, eviction of a deliberation segment becomes a durable checkpoint: the agent's step-31 re-encounter with the ambiguous date field triggers a tombstone lookup, retrieves the externalized step-9 decision, and continues under ISO-8601. The contradictory-branch corruption is impossible because the commitment is checked, not re-derived. ..."
  },
  "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": "b609b921e24393bef38cc69b7a612b98d3b597ff5102df5291d27a58a9dc3ec2",
    "verified_classes": [
      "NonDerivableEvictionError",
      "Segment"
    ],
    "verified_functions": [
      "evict_to_budget",
      "lookup_commitment",
      "__init__"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "NonDerivableEvictionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
