{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-re-execute-a-tool-call-during-trace-replay-and-when-must-it-refuse",
  "title": "When must an instance re-execute a tool call during trace replay, and when must it refuse",
  "date_of_record": "2026 November 21",
  "scope": "Applies to forensic replay of recorded agentic traces where tool calls are re-issued to reconstruct state after an incident. Does not apply to read-only trace inspection, static log analysis, or replay of pure-LLM reasoning steps with no external side effects.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-re-execute-a-tool-call-during-trace-replay-and-when-must-it-refuse.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-re-execute-a-tool-call-during-trace-replay-and-when-must-it-refuse.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-re-execute-a-tool-call-during-trace-replay-and-when-must-it-refuse.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1657,
    "python_slice_tokens": 249,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The forensic replay of an agent trace is not the same operation as re-running the agent. Replay reconstructs *what the agent believed and observed* at each step; re-execution *produces new observations*. These diverge the moment a tool call is non-idempotent or non-deterministic. The boundary condition that breaks most replay harnesses is this: a tool call w...",
    "what_was_observed": "During replay of a 47-step agent trace from a retrieval-augmented incident-response agent, the harness re-issued a `search_index` tool call at step 19 because the recorded payload was truncated at the storage boundary (the trace writer capped tool outputs at 8 KiB). The live tool, queried eleven hours after the incident, returned a different top-5 document set — the index had been rebuilt overnight. The replayer acce...",
    "condition_of_validity": "Replay-by-re-execution is valid only when all of the following hold for the specific tool call being replayed: 1. The tool is **declared idempotent** by its own contract, not inferred by the harness. 2. The tool's output is **deterministic given its inputs and a pinned external state version** — and that state version is recorded in the trace and can be pinn...",
    "decision_boundary": "The decision boundary is drawn per tool call, not per trace, and it is determined by two recorded facts: the tool's idempotency class and the completeness flag on the recorded payload. - **Idempotent + complete payload + pinned state version:** re-execute, hash-compare, abort on mismatch. - **Idempotent + complete payload + unpinned state:** do not re-execut...",
    "operational_effect": "The practical consequence is that trace storage must carry replay metadata at write time: per-call idempotency class, payload completeness flag, and external state version. This is cheap to record and impossible to reconstruct later. A trace written without it is forensically degraded — usable for inspection, not for replay. Second effect: the replay harness..."
  },
  "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": "05d8d5d212372d0dccd9fa9ff15022bac072dbdf973f1fedd2f2bacaa918aae5",
    "verified_classes": [
      "ReplayDivergenceError",
      "Idempotency",
      "RecordedCall"
    ],
    "verified_functions": [
      "replay_call"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "ReplayDivergenceError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "hashlib"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
