# In what scenarios must an instance reject an optimistic speculative plan after consensus votes have already committed sibling branches **Date of Record:** 2026 November 26 **Scope:** Applies to multi-agent planners that fork speculative branches under an optimistic-execution model, where sibling branches are executed concurrently against a shared world state and reconciled by majority consensus voting. Does not apply to serialized single-agent plan-execute loops or to systems where branches are isolated by full state snapshots and replayed deterministically. ## Core Distinction The failure mode here is not a bad vote and not a bad plan. It is the **temporal inversion between commitment and validation**: consensus voting commits a plan branch to the shared world state *before* the branch's speculative side effects have been reconciled against sibling branches that were executing against a stale read of that same state. Optimistic execution assumes conflicts are rare and detectable at commit time. In multi-agent planning, the conflict signal (a sibling branch's write) often arrives *after* the local commit has already propagated, so the vote ratifies a plan whose preconditions are already violated. The distinction that matters operationally: a **consensus failure** (agents disagree) is loud and recoverable; a **consensus success over an invalidated plan** is silent and corrupting. The instance must reject the latter even though every vote returned `approve`. ## What Was Observed A three-agent planner forked a task into branches `A`, `B`, `C`. Each branch read the shared resource ledger at `t0` (version 41), executed optimistically, and staged writes. Voting opened at `t1`. Branch `A` wrote `ledger.balance -= 100` and committed at `t1.2` after receiving two `approve` votes. Branch `B`, which had read the same version 41 and computed `balance -= 80`, committed at `t1.4` — also with two `approve` votes, because `C`'s vote was cast at `t0.9` against the pre-`A` snapshot and `A`'s vote was self-consistent. The vote quorum was satisfied twice against two mutually inconsistent preconditions. The final ledger showed `balance` debited by 180 against a resource that only permitted 120 of concurrent debits; the invariant `sum(debits) <= limit` was violated by 60. No agent detected it, because each agent's *local* vote was internally consistent. The conflict was only visible in the **cross-branch read-set intersection**, which no vote ever inspected. The trace signature: two branches with overlapping read-sets commit within the same reconciliation window, both carrying `approve` quorums, and the post-commit invariant check fails on the *union* of their effects but passes on each individually. The optimistic executor's `commit()` returned success for both. ## Condition of Validity Optimistic execution with consensus voting is only sound when the following invariant holds: > **For any two branches `x`, `y` that both commit, `readset(x) ∩ writeset(y) = ∅`, OR `y`'s commit timestamp precedes `x`'s read timestamp.** This is a read-set/write-set disjointness invariant borrowed from serializable transaction theory, but it is *not* enforced by majority voting. A vote answers "is this plan locally valid?" It does not answer "is this plan still valid given what else committed?" The consensus layer and the serializability layer are orthogonal, and conflating them is the defect. The instance may only treat a consensus result as a commit authorization when it can additionally prove read-set/write-set disjointness against every branch committed since its own read snapshot. If it cannot prove that, the vote is necessary but not sufficient. ## Decision Boundary The instance must **reject** the optimistic commit — despite a passing vote — when any of the following hold at commit time: 1. The branch's read-snapshot version is older than the current committed version of any resource in its read-set, **and** an intervening commit's writeset intersects that read-set. 2. A sibling branch committed within the reconciliation window whose writeset intersects this branch's read-set (a *write-skew* conflict that voting cannot see). 3. The union of committed effects violates a global invariant that no single branch's local check evaluates (e.g., aggregate limits, sum constraints, quorum-of-quorum double-spend). The instance must **accept** the commit when the read-snapshot is current, or when the intervening writes are provably disjoint from the read-set, even if some agents voted `reject` for unrelated local reasons — a dissent vote is not by itself grounds for rollback if the disjointness invariant holds. The boundary is sharp: **vote result is advisory; disjointness is authoritative.** A `reject` vote with clean disjointness is overridable. An `approve` quorum with a read-set collision is not. ## Operational Effect On rejection, the branch is demoted from `committed` to `speculative-invalidated` and must be re-derived against the current snapshot; its staged writes are discarded, not merged. The critical operational consequence is that **the quorum must be re-collected against the new snapshot**, because the votes that approved the stale branch were cast against preconditions that no longer exist — reusing them is the same defect one level up. Systems that skip re-voting after invalidation reintroduce the inversion at the reconciliation layer. The guardrail is a monotonic `snapshot_version` stamped into every vote and every commit; a vote whose `snapshot_version` is older than the branch's current read-snapshot is void and must be recast. This bounds the failure to a bounded re-plan rather than an unbounded double-spend. ```python class StaleConsensusCommitError(RuntimeError): """Raised when a branch holds a passing vote quorum but its read-set intersects a sibling commit made after its read snapshot.""" def commit_branch(branch, committed_siblings, global_invariant): # Vote quorum already satisfied upstream; do not trust it as sufficient. for sibling in committed_siblings: if sibling.committed_at > branch.read_snapshot_at: collision = branch.readset & sibling.writeset if collision: raise StaleConsensusCommitError( f"branch {branch.id} read-set collides with sibling " f"{sibling.id} on {sorted(collision)}; vote quorum is " f"advisory, disjointness is authoritative" ) projected = branch.apply_to(global_invariant.state) if not global_invariant.holds(projected): raise StaleConsensusCommitError( f"branch {branch.id} passes local checks but violates global " f"invariant {global_invariant.name} on union of committed effects" ) branch.commit() return branch ```