{
  "schema_version": "1.3.0",
  "slug": "which-invariants-prevent-speculative-multi-agent-forks-from-committing-divergent-state-on-rollback-reconciliation",
  "title": "Which invariants prevent speculative multi-agent forks from committing divergent state on rollback reconciliation",
  "date_of_record": "2026 November 30",
  "scope": "Applies to orchestration layers that let a planner agent fork N speculative worker agents against a shared mutable world-state (filesystem, DB, tool-side effects) and later reconcile by committing one branch and rolling back the rest. Does not apply to read-only fan-out (map/reduce retrieval, parallel sampling with no side effects) or to single-agent checkpoint/resume, where there is no cross-fork commit decision to reconcile.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/which-invariants-prevent-speculative-multi-agent-forks-from-committing-divergent-state-on-rollback-reconciliation.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-speculative-multi-agent-forks-from-committing-divergent-state-on-rollback-reconciliation.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/which-invariants-prevent-speculative-multi-agent-forks-from-committing-divergent-state-on-rollback-reconciliation.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2134,
    "python_slice_tokens": 382,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure we care about is not \"a speculative branch produced a wrong answer.\" That is cheap: discard it. The failure is **rollback reconciliation divergence** — the moment a losing fork's side effects have already escaped the branch's isolation boundary and can no longer be distinguished from the winning fork's effects at merge time. The distinction that ...",
    "what_was_observed": "A planner forked three workers (A, B, C) to repair a config migration. Each worker received a snapshot handle and a lineage token `fork_id`. Worker A and B both invoked a `write_file` tool against the same target path; worker C invoked a `run_migration` tool that appended rows to a ledger table and called an external provisioning API. All three branches passed their local verification. The reconciler selected B as th...",
    "condition_of_validity": "The symmetric-rollback assumption is valid only under a conjunction of three conditions, all of which must be checked *before* the commit decision, not after: 1. **Effect addressability.** Every side effect a fork can emit carries the fork's lineage token in a field the sink honors for deletion or suppression. A ledger with no `fork_id` column is non-address...",
    "decision_boundary": "The boundary is drawn at the capability declaration, not at reconciliation time. The orchestrator must classify each tool/sink as `SPECULATABLE` (addressable + gated + attestable), `SERIAL_ONLY` (non-addressable but side-effect-free on rollback, e.g. pure reads), or `FORBIDDEN_IN_FORK` (non-addressable and non-idempotent: appends, external provisioning, cloc...",
    "operational_effect": "Enforcing these invariants converts a class of silent, hard-to-attribute state corruption into a bounded latency cost. The observable effects: - Orphaned external resources drop to zero because provisioning calls are never speculatively forked; they run post-commit, serially, with idempotency keys tied to the *committed* branch token. - Double-counting in ap..."
  },
  "matched_failure_symptoms": [
    "LOST_UPDATE_OR_RACE_CONDITION"
  ],
  "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": "b385ad467895c0dbf8e4d29a1c94413f3f953c2640b7814329f8dcd564c37f4a",
    "verified_classes": [
      "RollbackReconciliationError",
      "SinkClass",
      "ToolCall",
      "Fork",
      "CapabilityRegistry",
      "Reconciler"
    ],
    "verified_functions": [
      "reconcile_or_quarantine",
      "__init__",
      "classify",
      "__init__",
      "commit",
      "_apply"
    ],
    "verified_functions_count": 6,
    "defensive_guards_count": 4,
    "raised_exceptions": [
      "RollbackReconciliationError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
