{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-treat-taint-lattice-joins-as-non-monotonic-across-tool-call-boundaries",
  "title": "How should an instance treat taint-lattice joins as non-monotonic across tool-call boundaries",
  "date_of_record": "2026 November 24",
  "scope": "Applies to single- or multi-agent runtimes that enforce taint-aware allow/deny gates on tool invocation, where a value's taint label is computed from the union of its inputs and then checked against a per-tool policy. Does not apply to pure prompt-level filtering, output classifiers, or sandboxing that ignores data provenance entirely.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-treat-taint-lattice-joins-as-non-monotonic-across-tool-call-boundaries.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-treat-taint-lattice-joins-as-non-monotonic-across-tool-call-boundaries.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-treat-taint-lattice-joins-as-non-monotonic-across-tool-call-boundaries.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1817,
    "python_slice_tokens": 391,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Most implementations treat taint propagation as a monotonic lattice join: `taint(out) = ⋃ taint(in_i)`, and a gate fires when `taint(args) ⊄ allowed(tool)`. The invariant everyone assumes is *monotonicity* — once a value is tainted, everything derived from it stays at least as tainted. That invariant holds for the *value graph* but silently breaks at the *to...",
    "what_was_observed": "A planner agent read an untrusted web page (`taint = UNTRUSTED:WEB`) and was asked to produce a one-line summary. The summarizer tool returned a plain `str`; the runtime assigned it `taint = TRUSTED:AGENT_OUTPUT` because the tool's declared return schema said `str` with no provenance annotation. The planner then called `send_email(to=..., body=<summary>)`. The gate for `send_email` allowed `TRUSTED:AGENT_OUTPUT` and ...",
    "condition_of_validity": "The monotonic taint invariant is only valid when *all three* of the following hold at every tool-call boundary: 1. **Return-label soundness.** For every tool `t`, `declared_taint(t(args)) ⊇ ⋃ taint(arg_i)`. If the tool can transform, summarize, or re-emit input content, its declared return taint must be at least the join of its actual arguments — not a stati...",
    "decision_boundary": "The runtime must choose between two enforcement postures at each boundary, and the choice is not free: - **Strict join (fail-closed on ambiguity):** if the return taint of a tool cannot be *proven* to dominate its inputs, the gate treats the output as `UNTRUSTED` regardless of the declared schema. This bounds laundering but breaks legitimate tools (a `format...",
    "operational_effect": "Enforcing the call-site join check converts silent laundering into a pre-execution refusal, which is observable, auditable, and attributable to a specific tool registration. The practical consequences: (a) tool authors must annotate return provenance as a function of input provenance, not as a constant; (b) the gate's deny path becomes a *registration* error..."
  },
  "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": "82fed95954305eafa8015b5949e2c8c73892c1dc56ca104b8655dc3ab13a04df",
    "verified_classes": [
      "TaintLaunderingError",
      "JoinOrderDefect",
      "TaintedValue",
      "Tool"
    ],
    "verified_functions": [
      "join",
      "invoke",
      "demo"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "JoinOrderDefect",
      "TaintLaunderingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
