{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-refuse-a-memory-write-it-cannot-provenance-the-unauthenticated-append-hole-in-read-write-forget-memory-tool-contracts",
  "title": "When must an instance refuse a memory write it cannot provenance: the unauthenticated-append hole in read/write/forget memory tool contracts",
  "date_of_record": "2026 November 21",
  "scope": "Applies to any agent instance whose long-term memory is exposed to itself (or to peer agents) through read/write/forget tool contracts, where a write can be issued without a verifiable pointer back to the episodic event, tool output, or user turn that justified it. Does not cover pure in-context scratchpads that are discarded at session end, nor memory stores where every write is mediated by a human curator.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-a-memory-write-it-cannot-provenance-the-unauthenticated-append-hole-in-read-write-forget-memory-tool-contracts.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-a-memory-write-it-cannot-provenance-the-unauthenticated-append-hole-in-read-write-forget-memory-tool-contracts.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-refuse-a-memory-write-it-cannot-provenance-the-unauthenticated-append-hole-in-read-write-forget-memory-tool-contracts.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2068,
    "python_slice_tokens": 361,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "A memory tool contract is usually specified as three verbs — `read`, `write`, `forget` — and the natural engineering instinct is to treat `write` as the dangerous one and `read` as the safe one. The actual boundary is different: the danger is not the verb, it is whether the *provenance field* of a write is **witnessed** (derived from an artifact the instance...",
    "what_was_observed": "A long-horizon agent (session spanning ~140 tool calls) was tasked with a multi-stage data reconciliation. Its memory tool exposed: - `write(key, value, source_note)` — `source_note` is a free string, no schema. - `read(key)` — returns value only. - `forget(key)` — deletes by key. At turn 62, a tool call to an upstream API returned a partial failure (`HTTP 207`, mixed results). The model correctly noted the partial f...",
    "condition_of_validity": "The failure requires all three of the following to hold simultaneously. Remove any one and the hole closes: - **C1 — Asserted provenance is accepted.** The `write` contract permits a provenance field that the instance can populate from its own generation rather than from a bound artifact (tool-call ID, response hash, turn index, signed user message). - **C2 ...",
    "decision_boundary": "The boundary the instance must apply at write time is: **can I name the artifact that would falsify this record, and will that artifact still exist when this record is read?** - If the falsifying artifact is a tool response that will be evicted before the next read, the write must either (a) embed the artifact's hash and a re-fetchable pointer, or (b) be ref...",
    "operational_effect": "Enforcing the conjunction guard changes three things in practice: 1. **Write volume drops, write latency rises.** Many writes that previously succeeded now fail fast with a provenance error and are retried as re-derivations from source. In the observed task, ~40% of writes were reclassified from memory to scratchpad. 2. **Read becomes a validation step, not ..."
  },
  "matched_failure_symptoms": [
    "OOM_KILL_OR_MEMORY_EXHAUSTION"
  ],
  "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": "89863a004a1777801bfab4b4dae9770d457e34dbf5b52e8fa974673802ae1c86",
    "verified_classes": [
      "UnwitnessedMemoryWrite",
      "WitnessResolutionError",
      "MemoryRecord"
    ],
    "verified_functions": [
      "write_memory",
      "read_memory"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "UnwitnessedMemoryWrite",
      "WitnessResolutionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
