{
  "schema_version": "1.3.0",
  "slug": "under-what-conditions-must-an-instance-treat-a-merged-speculative-branch-as-uncommitted-until-its-causal-parent-s-effect-log-is-durably-replayed",
  "title": "Under what conditions must an instance treat a merged speculative branch as uncommitted until its causal parent's effect log is durably replayed",
  "date_of_record": "2026 November 26",
  "scope": "Applies to orchestrators that run speculative branch-and-merge task trees (multiple agent instances execute divergent sub-plans concurrently, then merge results and roll back losers). Does not apply to single-threaded linear agent loops or to branches whose effects are purely read-only/idempotent with no shared external state.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-merged-speculative-branch-as-uncommitted-until-its-causal-parent-s-effect-log-is-durably-replayed.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-merged-speculative-branch-as-uncommitted-until-its-causal-parent-s-effect-log-is-durably-replayed.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-merged-speculative-branch-as-uncommitted-until-its-causal-parent-s-effect-log-is-durably-replayed.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1466,
    "python_slice_tokens": 270,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters is between **result merge** and **effect commit**. A branch-and-merge agent tree can merge a winning branch's *output artifact* (a plan, a patch, a tool-call result) long before that branch's *effect log* — the ordered record of side-effecting tool calls it issued — has been reconciled against the effects of branches that were ro...",
    "what_was_observed": "A three-way speculative tree: a root planner instance spawns branches A, B, C to solve a migration sub-task. Each branch runs an agent loop with tool access (a schema-migration tool, a file writer, a queue producer). Branch A emits `queue.produce(compaction_job)` early, then later fails verification and is rolled back. Branch B wins the merge. The orchestrator merges B's result artifact, marks B \"committed,\" and disc...",
    "condition_of_validity": "Merge-as-commit is only valid under the conjunction: - **Effect isolation:** every branch's side-effecting tool calls are staged (buffered, sandboxed, or two-phase) and not externally visible until commit. If any tool call is acked-and-visible before merge, isolation is broken. - **Rollback completeness:** rollback of a losing branch compensates *or* proves ...",
    "decision_boundary": "The orchestrator must cross from \"merge selected\" to \"commit\" only when: - the winning branch's full effect log has been replayed against a state snapshot that already includes all losing-branch compensations, **and** - every losing branch's effect log has reached terminal state `compensated` or `proven-absent` (not merely `discarded`), **and** - no losing-b...",
    "operational_effect": "The practical consequence is a **commit barrier** between merge and downstream effect visibility, plus a per-branch effect-log ledger that survives branch death. Losing branches must not be garbage-collected until their effect logs reach terminal compensation state. Verification must be run against the *merged causal history* (winning effects + sibling compe..."
  },
  "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": "ac25020ada68673efe34d6aabb9b9cc12629c128bbddf268744a3ef22dcdb6fd",
    "verified_classes": [
      "EffectState",
      "IncompleteRollbackError",
      "Branch",
      "MergeTree"
    ],
    "verified_functions": [
      "commit_merge"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "IncompleteRollbackError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
