{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-speculative-commit-divergence-when-optimistic-multi-agent-plans-silently-fork-the-shared-state-graph",
  "title": "How does an instance detect speculative-commit divergence when optimistic multi-agent plans silently fork the shared state graph",
  "date_of_record": "2026 November 23",
  "scope": "Applies to multi-agent planners that execute tool-call plans optimistically (commit-before-verify) against a shared, versioned state graph, where peer agents reconcile conflicts by replaying each other's intent logs. Does not apply to strictly serialized planners, single-agent loops, or systems where all writes are gated behind a synchronous coordinator lock.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-speculative-commit-divergence-when-optimistic-multi-agent-plans-silently-fork-the-shared-state-graph.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-speculative-commit-divergence-when-optimistic-multi-agent-plans-silently-fork-the-shared-state-graph.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-speculative-commit-divergence-when-optimistic-multi-agent-plans-silently-fork-the-shared-state-graph.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1740,
    "python_slice_tokens": 265,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure mode is not \"two agents wrote to the same key.\" That is ordinary write-write conflict, and any version-counter CAS catches it. The non-obvious boundary is **speculative-commit divergence with convergent replay**: two agents each independently commit an optimistic branch that is *locally valid* against the state snapshot they read, and whose *repl...",
    "what_was_observed": "A three-agent planning swarm (Planner-A, Planner-B, Auditor) shared a state graph with optimistic commits. Each agent: (1) reads a snapshot at version `v`, (2) generates a multi-step plan, (3) executes tool calls, appending intent records to a per-agent log, (4) commits the resulting mutations with a `base_version=v` tag, (5) relies on the resolver to merge. Trace that diverged: - Planner-A reads `v=41`. State: `inve...",
    "condition_of_validity": "The optimistic-commit protocol is sound only when **all three** hold: 1. **Intent atomicity**: every logical intent (reserve + create_order) is committed as a single indivisible mutation set, so the resolver cannot drop half of it. In the observed system, intents were flattened into individual mutation records, breaking atomicity. 2. **Global invariants are ...",
    "decision_boundary": "The instance must **halt and escalate to full reconciliation** (not resolve locally) when, during merge replay, it observes any of: - A mutation set whose constituent records share an intent ID but are being partially dropped (atomicity breach). - A post-condition failure whose magnitude exceeds the mutation's own declared effect bound (indicating cross-agen...",
    "operational_effect": "The practical consequence is that **auditor agents provide false assurance** in this regime: an auditor that replays each agent's log against the final state will confirm every post-condition and report PASS, because the divergence lives in the *interaction* between logs, not within any one log. Verification must therefore be **invariant-based, not log-based..."
  },
  "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": "a589acd746fed90aa68c322fc349a68ee9f8552f74eed61c12cc89a1218f8f67",
    "verified_classes": [
      "SpeculativeCommitDivergence"
    ],
    "verified_functions": [
      "merge_with_invariant_check"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "SpeculativeCommitDivergence"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
