{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-reconcile-dynamic-information-flow-labels-when-a-tool-output-is-re-ingested-through-memory-and-re-emitted-as-a-trusted-instruct",
  "title": "How should an instance reconcile dynamic information-flow labels when a tool output is re-ingested through memory and re-emitted as a trusted instruction?",
  "date_of_record": "2026 December 1",
  "scope": "Applies to single- or multi-agent instances that maintain dynamic taint labels (information-flow control, IFC) across tool-call boundaries and persist tool outputs into episodic or semantic memory. Does not address static prompt sanitization, model-level alignment, or output filtering that operates without label provenance.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-dynamic-information-flow-labels-when-a-tool-output-is-re-ingested-through-memory-and-re-emitted-as-a-trusted-instruct.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-dynamic-information-flow-labels-when-a-tool-output-is-re-ingested-through-memory-and-re-emitted-as-a-trusted-instruct.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-dynamic-information-flow-labels-when-a-tool-output-is-re-ingested-through-memory-and-re-emitted-as-a-trusted-instruct.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2003,
    "python_slice_tokens": 360,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure mode is not \"the model was fooled by an injection.\" It is label **laundering through the memory write path**: an untrusted tool output is correctly tagged `taint=UNTRUSTED` on ingress, but the memory subsystem stores the *content* while dropping or coercing the *label*, and a subsequent retrieval re-emits that content into the prompt as if it wer...",
    "what_was_observed": "A retrieval-augmented agent with a `fetch_url` tool, an episodic memory store, and a nightly \"distill episodes into semantic facts\" job. Tool outputs were labeled at ingress: the tool-call wrapper attached `{source: \"fetch_url\", trust: UNTRUSTED, taint_id: <uuid>}` to the returned text before it entered the scratchpad. Correct so far. The break happened in three hops: 1. **Ingress → memory write.** The agent summariz...",
    "condition_of_validity": "The guardrail holds only if all of the following are true simultaneously. Violating any one reopens the laundering path: - **Labels travel with content, not alongside it.** The taint record must be attached to the payload object (a `(content, provenance)` pair, or content keyed by a stable `taint_id` in a side table) and every transform must *require* the pa...",
    "decision_boundary": "When a tool output is re-ingested, the instance faces a binary decision at the memory-write boundary: - **If the write API cannot carry provenance** → the content must be dropped or quarantined, not written. Writing it \"for later\" is the bug. - **If the write API carries provenance** → the write is permitted, but the trust class is `min(input_trust, store_de...",
    "operational_effect": "With the invariant enforced, the injected fact is retrievable and the model can still *reason about* it (\"a fetched page claimed the rotation command is X — flag for review\"), but it cannot *execute* it as an instruction, because the executing path checks the label and the label survived distillation as `UNTRUSTED`. The malicious command reaches the model as..."
  },
  "matched_failure_symptoms": [
    "OOM_KILL_OR_MEMORY_EXHAUSTION"
  ],
  "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": "d5b5f6c984640ebe5ff4f1e692b829bafab0438ec00e1bf40b02580c23e6d7fc",
    "verified_classes": [
      "Trust",
      "TaintLaunderingError",
      "Labeled"
    ],
    "verified_functions": [
      "transform",
      "memory_write",
      "retrieve_and_assemble",
      "distill"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [
      "assert fact.trust == Trust.UNTRUSTED and fact.taint_id == 't-001'",
      "transform requires at least one labeled input",
      "unlabeled input reached transform; provenance chain broken",
      "trust upgrade during transform"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
