{
  "schema_version": "1.3.0",
  "slug": "why-does-an-instance-s-speculative-tool-call-cache-silently-alias-distinct-planner-branches-when-the-verifier-gate-admits-a-sibling-commit",
  "title": "Why does an instance's speculative tool-call cache silently alias distinct planner branches when the verifier gate admits a sibling commit?",
  "date_of_record": "2026 November 28",
  "scope": "Applies to agents that run multiple speculative planner branches against a shared tool-call cache and admit results only through a verifier-gated commit. Does not apply to single-branch linear planners, or to caches keyed on a canonicalized full-context hash with no branch multiplexing.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/why-does-an-instance-s-speculative-tool-call-cache-silently-alias-distinct-planner-branches-when-the-verifier-gate-admits-a-sibling-commit.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-s-speculative-tool-call-cache-silently-alias-distinct-planner-branches-when-the-verifier-gate-admits-a-sibling-commit.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-s-speculative-tool-call-cache-silently-alias-distinct-planner-branches-when-the-verifier-gate-admits-a-sibling-commit.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1764,
    "python_slice_tokens": 288,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not a cache miss and not a verifier rejection. It is a **cache hit on the wrong branch**. Speculative planning forks the agent's reasoning into N candidate trajectories that share a tool-call cache to amortize latency. Each branch proposes calls like `search(query)` or `read_file(path)`. If two branches emit a *syntactically identical* tool ca...",
    "what_was_observed": "A planning agent was configured with fan-out 4: it spawned four speculative branches from a shared prompt, each pursuing a different hypothesis about a codebase bug. Branches shared a `ToolCache` keyed on `(tool_name, frozenset(args.items()))`. The verifier gated commits by replaying each branch's plan against cached evidence and checking that every claim in the final answer was entailed by some tool result. Branch 1...",
    "condition_of_validity": "The guardrail is a **branch-scoped cache key plus a provenance check at commit**. The key must include a hash of the planner state that generated the call — specifically the branch's hypothesis identifier and the sequence of prior tool results the branch has consumed, not merely the call arguments. Two calls with identical arguments from different planner st...",
    "decision_boundary": "The boundary is between **sharing for latency** and **sharing for correctness**. Share the cache when the planner state digest is part of the key; do not share when it is not. The decision rule: - If `fan_out > 1` and branches can emit overlapping call signatures, the cache key **must** include the evidence digest. Argument-only keys are a correctness bug, n...",
    "operational_effect": "The observable symptom is a commit that is locally coherent and globally false: every claim is backed by a real tool result, but the result belongs to a sibling branch's world. Because the verifier passes, the error is not quarantined — it enters semantic memory tagged as verified, and later retrieval treats it as ground truth. The stale-memory drift that fo..."
  },
  "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": "7981ca0d7db9b9bba63413db47bfa0c147173607af6d5753a450407ef5fc08d0",
    "verified_classes": [
      "SpeculativeCacheAliasingError",
      "ToolResult",
      "Branch",
      "ProvenanceGatedCache"
    ],
    "verified_functions": [
      "verify_commit",
      "evidence_digest",
      "__init__",
      "_key",
      "fetch"
    ],
    "verified_functions_count": 5,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "SpeculativeCacheAliasingError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
