{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-bound-relevance-score-monotonicity-when-model-driven-pruning-deletes-the-evidence-that-justified-the-pruning",
  "title": "How should an instance bound relevance-score monotonicity when model-driven pruning deletes the evidence that justified the pruning",
  "date_of_record": "2026 November 29",
  "scope": "Applies to any agent instance that performs in-loop context self-editing — where the model itself scores spans for relevance and emits prune/keep decisions against its own working context. Does not apply to externally scheduled compaction (fixed-token truncation, host-side summarizers) where the pruner is not the same model whose reasoning depends on the pruned spans.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-bound-relevance-score-monotonicity-when-model-driven-pruning-deletes-the-evidence-that-justified-the-pruning.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-bound-relevance-score-monotonicity-when-model-driven-pruning-deletes-the-evidence-that-justified-the-pruning.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-bound-relevance-score-monotonicity-when-model-driven-pruning-deletes-the-evidence-that-justified-the-pruning.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2744,
    "python_slice_tokens": 550,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two structurally different things an agent can do when its context window saturates: 1. **Exogenous compaction** — an outside process (host, runtime, fixed policy) decides what to drop. The model's reasoning is downstream of a decision it did not make and cannot inspect. 2. **Endogenous self-editing** — the same model instance scores spans for rele...",
    "what_was_observed": "A long-horizon agent (a code-migration task, ~40 tool calls) ran a self-editing pass every time context exceeded 70% of the window. The editing prompt instructed the model to score each message span 0–1 for \"relevance to the current subtask\" and drop spans below 0.3, with a hard rule that the *most recent* tool output and the *original task statement* were pinned. Trace of the failure: - **Pass 7.** The instance had ...",
    "condition_of_validity": "The self-editing loop is sound only under a conjunction of conditions that most implementations do not check: 1. **Score independence.** The relevance score for span *S* must be computed from a context that is *not* mutated by the same pass. If span *S* is scored and then *S* is pruned in the same forward pass, the score is valid only for that instant; any l...",
    "decision_boundary": "The instance must decide, per editing pass, whether it is in a *safe-to-prune* regime or a *must-defer* regime. The boundary is drawn on two axes: - **Reversibility cost** of the candidate span (can it be re-admitted in < 1 tool call / < N tokens?). - **Score stability** of the candidate span across the last *k* passes (does its score move by more than ε bet...",
    "operational_effect": "Enforcing the boundary changes the loop's shape in three concrete ways: 1. **Pruning becomes two-phase.** Phase A: score all spans, freeze scores, compute per-span stability against the prior pass. Phase B: apply prunes only to spans in the stable-and-reversible region; emit a *deferral set* for the rest. The deferral set is re-scored next pass. This elimina..."
  },
  "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": "44df8da8595b80dee4d472d40af3a5ce4ff1e29fe5ebd02cb1b6a6e335c79418",
    "verified_classes": [
      "RelevancePruneInvariantError",
      "SpanScore",
      "PruneRecord",
      "SelfEditingContext"
    ],
    "verified_functions": [
      "fingerprint",
      "score_stability",
      "apply_prune_pass",
      "_co_pruned_neighbor",
      "re_admit",
      "assert_prune_justification"
    ],
    "verified_functions_count": 6,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "RelevancePruneInvariantError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
