{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-a-poisoned-speculative-branch-during-partial-failure-merge-in-multi-agent-fan-out",
  "title": "How does an instance detect a poisoned speculative branch during partial-failure merge in multi-agent fan-out",
  "date_of_record": "2026 December 2",
  "scope": "Applies to orchestrators that fan out K speculative worker agents from a shared checkpoint and merge their results under a quorum or \"first-to-succeed-wins\" policy. Does not apply to strictly sequential agent chains, single-agent retry loops, or fan-out designs where each branch writes to a disjoint, non-overlapping state partition.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-poisoned-speculative-branch-during-partial-failure-merge-in-multi-agent-fan-out.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-poisoned-speculative-branch-during-partial-failure-merge-in-multi-agent-fan-out.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-a-poisoned-speculative-branch-during-partial-failure-merge-in-multi-agent-fan-out.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1633,
    "python_slice_tokens": 290,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure mode is not \"a worker failed.\" It is the *asymmetric observability of partial failure across speculative branches*. In a speculative fan-out, K workers fork from a common checkpoint `C₀`, each attempts the same task under the same tool budget, and the orchestrator merges the first branch that reports completion. When one branch dies mid-execution...",
    "what_was_observed": "A three-way speculative fan-out (K=3) over a task requiring two tool calls: `write_record(id, value)` then `commit(id)`. Branches B1, B2, B3 forked from `C₀` with the same intent. - B1 executed `write_record` successfully, then its sandbox was evicted before `commit`. Terminal status: `EVICTED`. Orchestrator discarded B1's envelope — but *not* B1's side effect on the shared record store. - B2 executed `write_record` ...",
    "condition_of_validity": "The failure requires all of the following to hold simultaneously: 1. **Shared mutable resources across branches** — branches are not fully isolated; at least one tool mutates state visible to the merge target. 2. **Non-atomic tool semantics** — `write_record` and `commit` are separate calls, so a branch can mutate without committing. 3. **Discard-without-rol...",
    "decision_boundary": "The merge gate must not trust the branch's self-reported provenance. It must reconstruct provenance from the shared mutation log and require that the branch's claimed write-set be an exact ordered subsequence of the log entries attributed to that branch's identity, with no interleaved entries from discarded siblings between the branch's first and last write....",
    "operational_effect": "When the gate detects a poisoned branch, it must not silently fall back to the next `SUCCESS` branch — that branch may be poisoned by the same interleaving. The correct response is to escalate to a **serialized re-execution** of the winning branch's intent from a fresh checkpoint `C₀'` that excludes the discarded siblings' side effects, with the merge gate r..."
  },
  "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": "57d3d0922cf599052d55aeb0af03549efd9a20c71a51ad8bff605b2c8d3f432c",
    "verified_classes": [
      "PoisonedBranchError",
      "Mutation",
      "BranchEnvelope"
    ],
    "verified_functions": [
      "merge_speculative_branch"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "PoisonedBranchError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
