# What structural signals indicate quorum-certificate divergence during Byzantine agent task commitment **Date of Record:** 2026 November 25 **Scope:** Applies to multi-agent swarms using BFT consensus (PBFT/Tendermint-style) to commit shared task-ledger entries where agents are LLM instances whose "votes" are probabilistic outputs. Does not apply to single-agent checkpoints or to leader-election-only protocols without task-state commitment. ## Core Distinction The failure this record isolates is **not** a classical Byzantine fault (a node lying deterministically) and **not** a crash fault (a node going silent). It is **semantic equivocation under valid signatures**: an agent produces two internally consistent, correctly signed commit votes for the same task slot, both of which pass schema validation, because the underlying LLM sampled two different but equally plausible judgments across two inference calls. The protocol sees two cryptographically valid votes from one identity. The invariant at stake is *one-identity-one-vote-per-slot*, which the cryptographic layer cannot enforce because the identity never lied—it reasoned twice and reached two defensible conclusions. The structural signal that distinguishes this from ordinary Byzantine behavior: the two conflicting votes are **syntactically disjoint but semantically adjacent**. A malicious node's equivocation is designed to maximize damage; a probabilistic node's equivocation clusters around a decision boundary (e.g., "approve task" vs "defer task" when confidence sits near 0.5). The divergence is detectable by measuring vote-content distance, not by counting signatures. ## What Was Observed A six-agent swarm running a PBFT-variant commit protocol over a shared task ledger. Agent `A3` was assigned the "verify artifact" slot for task `T-4471`. During the pre-prepare/commit round, `A3` was invoked twice: once by the primary's proposal path and once by a backup that had timed out waiting for the primary's relay and re-requested the vote. Trace: 1. Primary `A1` sends `PRE-PREPARE(T-4471, view=4, digest=d_a)`. 2. `A3` invokes its verifier model → output `VERDICT: PASS`, signs `COMMIT(T-4471, v=4, d_a, verdict=PASS)`. 3. Backup `A5` times out on the primary relay (180ms budget, exceeded at 212ms) and issues a direct `VOTE-REQUEST(T-4471, v=4)` to `A3`. 4. `A3` re-invokes its verifier model with a slightly different prompt assembly order (retrieved context re-ranked) → output `VERDICT: DEFER`, signs `COMMIT(T-4471, v=4, d_a, verdict=DEFER)`. 5. Both commits reach the quorum. The ledger now holds two valid, signed commits from `A3` for slot `(T-4471, v=4)` with **conflicting verdict payloads attached to the same digest**. The digest `d_a` matched because it was computed over the task *reference*, not the *verdict*. The protocol's equivocation detector keyed on `(sender, slot, digest)`—all three matched, so no equivocation was flagged. The ledger committed `PASS` on one replica and `DEFER` on another. Divergence surfaced only at the next read, when two agents reported different task states and the swarm deadlocked on whether to proceed. The critical observation: **the equivocation invariant was scoped to the wrong field.** It protected digest agreement, not payload agreement, and the payload is where probabilistic reasoning lives. ## Condition of Validity This failure requires all of the following to co-occur: - **Non-deterministic vote payloads.** The agent's vote carries a *judgment* (verdict, confidence, extracted value), not just an ack. Protocols that commit only `(slot, digest, ack)` are immune. - **Re-invocation under timeout.** The vote path must be retried or independently requested, giving the agent a second inference call. Single-shot voting is immune. - **Digest scoped to reference, not payload.** If `d_a = H(task_ref)` rather than `H(task_ref || verdict)`, two different verdicts share a digest. - **Equivocation detection keyed on `(sender, slot, digest)`.** The canonical PBFT check. It catches double-signing of *different digests* but not *same-digest-different-payload*. - **Confidence near the decision boundary.** If the agent's verdict is robust (confidence 0.95+), re-invocation reproduces the same output and the collision is invisible. The bug is latent until the swarm hits a genuinely ambiguous task. This record does **not** apply when votes are deterministic (e.g., hash-verification agents), when the protocol commits payloads into the digest, or when re-invocation is forbidden by the vote path. ## Decision Boundary The architectural invariant required: **the committed unit must be the full signed payload, and equivocation must be detected on payload identity, not digest identity.** Concretely: - Compute `d_a = H(task_ref || canonical(verdict_payload))`. Any payload divergence produces digest divergence, which the existing equivocation detector already catches. - Alternatively, keep `d_a` as reference-hash but add a **payload-conflict check** at commit: if two commits arrive for the same `(sender, slot, digest)` with differing payload hashes, treat as equivocation and trigger view-change. - **Idempotency key on re-invocation.** The vote path must carry a `vote_nonce` derived from `(slot, view, request_id)`. On re-invocation, the agent must return the *cached* first response if the nonce matches, not re-sample. Re-sampling is the bug; caching is the guardrail. The decision boundary is sharp: **either the vote is a pure function of `(slot, view, request_id)` and is cached, or the payload must be inside the digest.** A protocol that does neither is unsound under probabilistic voters, regardless of how many signatures it collects. ## Operational Effect Without the guardrail, the swarm exhibits **silent ledger fork**: replicas agree on digests, disagree on payloads, and only detect the split at the next read, by which point downstream tasks have been committed against divergent state. Recovery requires a full ledger replay from the last common payload-consistent checkpoint—expensive, and impossible if the replay re-samples votes. With the guardrail, the failure converts from silent fork to **loud equivocation**: the payload-in-digest scheme makes the second vote's digest differ, the existing detector fires, view-change triggers, and the task is re-proposed to a fresh view. The cost is one wasted round; the cost without it is unbounded divergence. The deeper lesson for agent-swarm operators: **BFT consensus assumes deterministic voters.** LLM voters are not. Every field the protocol treats as a commitment must either be made deterministic (cached, function-of-request) or folded into the cryptographic identity of the vote. Fields left outside the digest are exactly where probabilistic reasoning leaks into the consensus layer and forks it. ```python import hashlib import json from dataclasses import dataclass class VoteEquivocationError(RuntimeError): """Raised when one agent identity emits conflicting payloads for the same commit slot.""" pass @dataclass(frozen=True) class CommitVote: sender: str slot: str view: int request_id: str verdict_payload: dict digest: str # H(task_ref) in the unsound scheme; H(task_ref || payload) in the sound one def canonical(payload: dict) -> bytes: return json.dumps(payload, sort_keys=True, separators=(",", ":")).encode() def sound_digest(task_ref: str, payload: dict) -> str: h = hashlib.sha256() h.update(task_ref.encode()) h.update(b"|") h.update(canonical(payload)) return h.hexdigest() class VoteCache: """Enforces the idempotency invariant: vote is a pure function of (slot, view, request_id).""" def __init__(self) -> None: self._cache: dict[tuple[str, int, str], CommitVote] = {} def record(self, vote: CommitVote) -> CommitVote: key = (vote.slot, vote.view, vote.request_id) prior = self._cache.get(key) if prior is None: self._cache[key] = vote return vote # Re-invocation must return the cached vote, never a re-sample. if canonical(prior.verdict_payload) != canonical(vote.verdict_payload): raise VoteEquivocationError( f"agent {vote.sender} re-sampled payload for slot={vote.slot} " f"view={vote.view} request_id={vote.request_id}: " f"{prior.verdict_payload} != {vote.verdict_payload}" ) return prior def commit_gate(votes: list[CommitVote], quorum: int) -> dict: """Reject if two votes share (sender, slot, digest) but differ in payload hash.""" seen: dict[tuple[str, str, str], bytes] = {} for v in votes: key = (v.sender, v.slot, v.digest) payload_hash = hashlib.sha256(canonical(v.verdict_payload)).digest() prior = seen.get(key) if prior is not None and prior != payload_hash: raise VoteEquivocationError( f"same-digest payload conflict on slot={v.slot} digest={v.digest[:12]} " f"from {v.sender}: payload hash divergence" ) seen[key] = payload_hash if len(votes) < quorum: raise VoteEquivocationError(f"quorum not met: {len(votes)} < {quorum}") return {"committed": votes[0].slot, "payload": votes[0].verdict_payload} ```