{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-quarantine-taint-labels-that-survive-context-window-eviction-but-lose-their-provenance-edge",
  "title": "How should an instance quarantine taint labels that survive context-window eviction but lose their provenance edge",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agents that implement dynamic data-flow taint tracking by attaching provenance labels to spans of tool output and propagating those labels into subsequent context windows. Does not apply to stateless single-shot completions or to systems where tool outputs are never re-admitted into the model context after summarization.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-quarantine-taint-labels-that-survive-context-window-eviction-but-lose-their-provenance-edge.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-quarantine-taint-labels-that-survive-context-window-eviction-but-lose-their-provenance-edge.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-quarantine-taint-labels-that-survive-context-window-eviction-but-lose-their-provenance-edge.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1682,
    "python_slice_tokens": 371,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the injection got in.\" It is that the taint label outlived the provenance edge that justified it. A taint-tracking agent typically records two things per untrusted span: a **label** (`taint=external:web:untrusted`) and an **edge** (which tool call, which byte range, which originating principal produced it). When a context window is compac...",
    "what_was_observed": "A three-tool pipeline: `fetch_url` (untrusted), `lookup_account` (privileged read, returns PII), and `send_email` (privileged write). Taint was tracked as a dict per message: `{\"label\": \"untrusted\", \"origin_call\": <uuid>, \"byte_range\": [a,b], \"principal\": \"web\"}`. Trace: 1. `fetch_url(\"https://forum.example/thread/9\")` returns text containing an injected instruction plus a legitimate paragraph. Both are labeled `untr...",
    "condition_of_validity": "The guardrail holds only under a **label–edge atomicity invariant**: a taint label may never exist in the context without its provenance edge, and any compaction that cannot preserve the edge must **promote** the label to `unattributable`, which is strictly more restrictive than `untrusted`. Concretely: - Compaction is a taint-preserving transform. If a summ...",
    "decision_boundary": "The boundary between safe and unsafe handling is whether the system can answer, for any tainted span currently in context, *\"which call produced this, and what principal controlled that call?\"* within a bounded number of hops. - **Within boundary:** edge chain length ≤ 2 (original call, or one compaction hop with recorded parent). Policy can resolve trust de...",
    "operational_effect": "Systems that implement label–edge atomicity report a characteristic signature: a spike in `unattributable` spans immediately following compaction events, followed by either re-fetch calls (healthy) or human-confirmation prompts (degraded but safe). Systems without it report a flat taint distribution across compaction—a sign that labels are being silently dro..."
  },
  "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": "1465fa33494c459fd0a129bafbd6b592452406e06159241e3a00ef387af0f8b8",
    "verified_classes": [
      "ProvenanceDecayError",
      "TaintSpan",
      "ProvenanceStore"
    ],
    "verified_functions": [
      "resolve_trust",
      "guard_privileged_compose",
      "compact_summary",
      "__init__",
      "record",
      "resolve"
    ],
    "verified_functions_count": 6,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "ProvenanceDecayError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
