{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-reconcile-non-idempotent-side-effects-across-speculative-multi-agent-branches-when-a-rollback-checkpoint-is-taken-after-a-tool",
  "title": "How should an instance reconcile non-idempotent side effects across speculative multi-agent branches when a rollback checkpoint is taken after a tool call has already committed externally",
  "date_of_record": "2026 November 13",
  "scope": "Applies to orchestrators that run multiple agent branches speculatively against shared tool endpoints, take rollback checkpoints to prune losing branches, and assume checkpoint rollback restores observable world state. Does not apply to branches whose tool calls are provably pure, or to systems where every tool call is wrapped in a two-phase commit with an external coordinator.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-non-idempotent-side-effects-across-speculative-multi-agent-branches-when-a-rollback-checkpoint-is-taken-after-a-tool.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-non-idempotent-side-effects-across-speculative-multi-agent-branches-when-a-rollback-checkpoint-is-taken-after-a-tool.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-non-idempotent-side-effects-across-speculative-multi-agent-branches-when-a-rollback-checkpoint-is-taken-after-a-tool.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1281,
    "python_slice_tokens": 214,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "A rollback checkpoint restores *internal* agent state: conversation history, scratchpad, working memory, the branch's view of the world. It does not, and cannot, restore *external* state mutated by a tool invocation that has already returned a success status to the caller. The non-obvious boundary is temporal: the checkpoint is taken at branch-fork time, but...",
    "what_was_observed": "During a branch-and-prune run over a tool surface containing `create_ticket`, `send_message`, and `append_ledger_entry`, three sibling branches were forked from a common checkpoint. Branch A issued `create_ticket` and received `201 Created` with a resource ID; the branch then failed a downstream validation and was pruned. Branch B, the winner, issued a logically equivalent `create_ticket` and received a *different* r...",
    "condition_of_validity": "The safe invariant is: *a checkpoint may only be rolled back across tool calls whose effects are either (a) reversible by a compensating action the orchestrator can issue, or (b) deduplicated by a key that is invariant across branch identity and replay.* Speculative rollback is valid only when every tool call between fork and prune carries a logical-operatio...",
    "decision_boundary": "The boundary is the moment a tool call commits externally. Before commit, prune is free. After commit, prune incurs an obligation: either the orchestrator records the committed effect against the *logical operation* (not the branch) and suppresses sibling attempts, or it schedules a compensating action and refuses to treat the checkpoint as restored. The dec...",
    "operational_effect": "When the boundary is respected, speculative fan-out remains cheap: sibling branches share idempotency keys, the first commit wins at the tool, and pruned siblings' calls are absorbed by deduplication rather than replayed. When it is violated, the system accumulates orphan effects proportional to branch fan-out and prune rate, and reconciliation passes that t..."
  },
  "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": "1cc006afb76ea660528aa9b2ec38c90f6a0b4037d66fe95fac8c7ac4c6a050a9",
    "verified_classes": [
      "SpeculativeRollbackViolation"
    ],
    "verified_functions": [
      "prune_branch",
      "__init__"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "SpeculativeRollbackViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
