{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-discard-prefetched-tool-results-after-speculative-plan-decoding-diverges-from-the-committed-plan",
  "title": "When must an instance discard prefetched tool results after speculative plan decoding diverges from the committed plan",
  "date_of_record": "2026 November 24",
  "scope": "Applies to agents that decode a candidate plan and speculatively execute (prefetch) its tool calls before the plan is committed, then verify prefetched results against the committed plan. Does not apply to strictly sequential agents that execute only committed steps, nor to prefetching that is purely read-only and side-effect-free *and* whose results are re-fetched on commit.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-discard-prefetched-tool-results-after-speculative-plan-decoding-diverges-from-the-committed-plan.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-discard-prefetched-tool-results-after-speculative-plan-decoding-diverges-from-the-committed-plan.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-discard-prefetched-tool-results-after-speculative-plan-decoding-diverges-from-the-committed-plan.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1772,
    "python_slice_tokens": 287,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "Speculative prefetching conflates two different notions of \"the same tool call\": **token-level speculation** (the model's draft tokens for a step's arguments were accepted by the verifier) and **plan-level equivalence** (the committed plan's step is semantically the same call as the one whose result you already hold). These come apart precisely because specu...",
    "what_was_observed": "A planner agent runs speculative decoding over plan steps. For step 3 it drafts `write_file(path=\"/etc/agent/conf.d/\", mode=\"append\", body=...)` and, because draft acceptance probability was high through the `path` and `mode` tokens, the executor prefetches the call at draft time. The verifier rejects the draft at the `body` token boundary (target model assigns low probability to the draft continuation) and resamples...",
    "condition_of_validity": "The committability check is valid only under the following conditions, and each is independently falsifiable: - **Full-tuple identity, canonically serialized.** The comparison must be over the committed step's arguments after canonicalization (key ordering, numeric normalization, default-filling), compared to the *exact* argument tuple the prefetch executor ...",
    "decision_boundary": "The boundary is between **prefetch-as-optimization** and **prefetch-as-speculation-on-state**. Prefetch is safe as an optimization when the prefetched result is used only to warm caches, populate latency buffers, or pre-open connections — i.e., when discarding it costs only wasted work. It becomes unsafe the moment any consumer treats the prefetched result a...",
    "operational_effect": "The operational consequence is that speculative prefetching shifts cost from latency to **commit-time verification**, and that verification must be a hard gate, not a best-effort match. Systems that implement full-tuple identity see prefetch hit rates drop — often sharply, because mid-argument draft divergence is common for long free-text arguments (bodies, ..."
  },
  "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": "6ef5153c5168a323871f34df89b65cfc492bc9ddc8285ed2cdafad5ea2ff7cf2",
    "verified_classes": [
      "PrefetchCommitDivergence",
      "ToolCall",
      "PrefetchedResult"
    ],
    "verified_functions": [
      "bind_prefetch_to_commit",
      "canonical_bytes"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "PrefetchCommitDivergence"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
