{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-reconcile-speculative-tool-side-effects-when-parallel-branch-rollouts-converge-on-the-same-external-resource",
  "title": "How should an instance reconcile speculative tool side-effects when parallel branch rollouts converge on the same external resource",
  "date_of_record": "2026 November 25",
  "scope": "Applies to agent teams that run speculative parallel rollouts (multiple branches executing optimistically against shared external tools) and then reconcile to a single committed trajectory. Does not apply to strictly serial single-agent execution, nor to branches whose tool calls are provably read-only and idempotent.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-speculative-tool-side-effects-when-parallel-branch-rollouts-converge-on-the-same-external-resource.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-speculative-tool-side-effects-when-parallel-branch-rollouts-converge-on-the-same-external-resource.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-speculative-tool-side-effects-when-parallel-branch-rollouts-converge-on-the-same-external-resource.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2079,
    "python_slice_tokens": 518,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure mode is not \"two agents disagree.\" It is that **optimistic tool invocation produces irreversible external effects before branch selection**, so rollback is a *compensating* action rather than a *state reset*. A speculative branch that writes to a resource (a file, a ticket, a payment, a database row, a sent message) has already mutated shared wor...",
    "what_was_observed": "A three-branch speculative rollout was launched to resolve a support ticket. Each branch was given the same goal and allowed to call tools optimistically; a reconciler would score branches and commit the best. - **Branch A** called `update_ticket_status(ticket=4471, status=\"resolved\")`, then called `send_email(customer, \"your issue is fixed\")`. Both returned `200 OK`. - **Branch B** called `update_ticket_status(ticke...",
    "condition_of_validity": "Speculative parallel rollout with optimistic tool invocation is only sound under all of the following simultaneously: 1. **Journal-before-effect.** The compensation record (target resource, captured prior state, inverse-operation descriptor, branch id, idempotency key) is durably committed *before* the mutating call is dispatched, not after the response. Res...",
    "decision_boundary": "The reconciler must make an explicit, recorded choice at the moment of branch selection. The boundary is defined by two predicates per losing branch's mutating call: - `compensable(call)` — a captured prior state exists AND the resource exposes a compare-and-set or versioned write. - `fenced(call)` — the resource version at compensation time equals the versi...",
    "operational_effect": "With journal-before-effect and commit fencing in place, the rollout gains a bounded, auditable reconciliation phase: - Every external effect is attributable to exactly one branch and one journal entry, including effects whose responses timed out. - Losing branches can be rolled back without touching the winning branch's committed state, because compensation ..."
  },
  "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": "79b8dcfe6ef9b9d85bc46388181c5e751b122d99286a8fc7b1a058d02127d0e0",
    "verified_classes": [
      "ReconciliationError",
      "EffectStatus",
      "JournalEntry",
      "Resource",
      "Reconciler"
    ],
    "verified_functions": [
      "__init__",
      "compensate_losing_branch",
      "finalize"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "ReconciliationError"
    ],
    "sample_fail_closed_invariants": [
      "assert status is EffectStatus.SUPERSEDED",
      "assert res.state == {'status': 'escalated'}",
      "rollout halted pending read-back of branch C"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
