{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-re-derive-taint-labels-after-a-tool-round-trip-and-why-label-inheritance-silently-inverts-on-idempotent-re-reads",
  "title": "Where must an instance re-derive taint labels after a tool round-trip, and why label inheritance silently inverts on idempotent re-reads",
  "date_of_record": "2026 November 30",
  "scope": "Applies to any agent that carries information-flow (taint) labels across tool calls, RAG retrievals, and sub-agent handoffs, where a labeled value can be re-fetched, re-summarized, or re-serialized mid-task. Does not apply to single-turn, no-tool inference where provenance is fixed at prompt assembly time and never re-enters the context.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-taint-labels-after-a-tool-round-trip-and-why-label-inheritance-silently-inverts-on-idempotent-re-reads.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-taint-labels-after-a-tool-round-trip-and-why-label-inheritance-silently-inverts-on-idempotent-re-reads.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-re-derive-taint-labels-after-a-tool-round-trip-and-why-label-inheritance-silently-inverts-on-idempotent-re-reads.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2319,
    "python_slice_tokens": 446,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters is between **label propagation** and **label re-derivation**. Most taint-tracking designs treat a label as a property that *travels with a value*: a retrieved document is tagged `untrusted:web`, the tag rides along through the tool output, into the context window, through the summarizer, and out to the next tool call. This is pro...",
    "what_was_observed": "A research agent was tasked with \"summarize the current status of project X from the internal wiki, then draft an email to the owner.\" The wiki is served by an MCP tool `wiki.read(page_id)`. The tool returns `{content, revision, fetched_at}`. The agent's harness maintains a taint map keyed by `page_id`: first successful read of a page tags the content `trusted:internal`. Trace of the failure: 1. **Turn 1.** Agent cal...",
    "condition_of_validity": "Label inheritance is sound only under all three of the following, and the failure above violates at least one: - **Epoch stability.** The source's content and trust class are unchanged between the labeled fetch and any reuse. Concretely: `revision`/`etag`/`snapshot_id`/`content_hash` of the re-read equals that of the labeled fetch. If the source is mutable a...",
    "decision_boundary": "The boundary is: *when the agent re-encounters a value it has seen before, does it re-derive the label or inherit it?* - **Re-derive** when any of: the source returned a different version token; the value passed through a transform that did not carry provenance; the value is being merged with values of a different trust class; the fetch path changed (differe...",
    "operational_effect": "With re-derivation enforced, the trace above fails closed: the second `wiki.read` returns `revision: r42`, the harness sees the token mismatch, drops the inherited label, and re-derives `trusted:internal` *only if* the tool's trust class still holds—but the content hash differs, so the harness attaches `untrusted:internal-mutated` pending review. The `email...."
  },
  "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": "84fb4123215b1658f2051ea3a1add3a6e13f776c701c48ede3e973c27db20ac0",
    "verified_classes": [
      "TaintReDerivationError",
      "LabeledValue",
      "TaintTracker"
    ],
    "verified_functions": [
      "__init__",
      "ingest_tool_output",
      "summarize",
      "assert_send_allowed"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "TaintReDerivationError"
    ],
    "sample_fail_closed_invariants": [
      "cannot summarize zero inputs; provenance undefined"
    ],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
