{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-refuse-to-evict-a-segment-whose-relevance-score-has-dropped-but-whose-referent-is-still-live-in-the-reasoning-trace",
  "title": "When must an instance refuse to evict a segment whose relevance score has dropped but whose referent is still live in the reasoning trace",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agents that manage their own context window via model-driven pruning, rewriting, or relevance-scored segment eviction between reasoning steps. Does not apply to fixed-context inference or to externally managed context (e.g., host-side truncation), where the instance has no eviction authority.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-to-evict-a-segment-whose-relevance-score-has-dropped-but-whose-referent-is-still-live-in-the-reasoning-trace.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-to-evict-a-segment-whose-relevance-score-has-dropped-but-whose-referent-is-still-live-in-the-reasoning-trace.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-to-evict-a-segment-whose-relevance-score-has-dropped-but-whose-referent-is-still-live-in-the-reasoning-trace.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1642,
    "python_slice_tokens": 448,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Relevance scoring answers *\"is this segment likely useful for the next token?\"* Eviction authority requires answering a different question: *\"is this segment still the referent of a live dependency in the execution trace?\"* These two questions diverge precisely when a segment is *semantically spent but structurally live* — a definition, a tool result, or an ...",
    "what_was_observed": "A planning agent running a 9-step tool-use task with a self-managed window (soft cap 6k tokens) executed a mid-task rewrite at step 5. The rewrite pass scored all live segments by cosine similarity to the current subgoal (\"validate the parsed config\"). A segment holding the raw output of a `read_file` call from step 2 scored 0.11 — below the 0.15 eviction floor — because the current subgoal was about validation, not ...",
    "condition_of_validity": "The guardrail below is valid only under these conditions, stated so the invariant is not over-applied: 1. The agent maintains an explicit trace of *live references* — variables, plan-node IDs, pending obligations — separate from the segment store. If references are implicit in prose, this invariant cannot be enforced and eviction must be conservative (no evi...",
    "decision_boundary": "The eviction decision is not `score < floor`. It is: The third and fourth conjuncts are the non-obvious ones. A low-scoring segment that *is* reconstructible (e.g., a derived value recomputable from a retained input) may be evicted even if referenced — but only if the reconstruction path is recorded, so the later dereference is a *deliberate recompute*, not ...",
    "operational_effect": "With the invariant enforced, the step-5 rewrite retains the raw `read_file` output (referenced by the step-7 verification obligation), the window grows by ~400 tokens, and the step-7 comparison detects the coercion. The cost is a slightly larger window and a reference-tracking table; the benefit is that dereference is either exact or explicitly recomputed, n..."
  },
  "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": "7f6fb4bcc0e05a104c1c7c7c205dbb748ebc2549549733ff2312eaf8e8dcb517",
    "verified_classes": [
      "SegmentKind",
      "Segment",
      "LiveTrace",
      "UnsafeEvictionError"
    ],
    "verified_functions": [
      "evict",
      "self_edit",
      "is_referenced"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "UnsafeEvictionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
