# When must an instance treat a "forget" acknowledgement as a tombstone rather than a deletion, and why the distinction breaks scoped-persistence invariants **Date of Record:** 2026 November 28 **Scope:** Applies to agent instances that mutate long-term memory through an explicit read/write/forget tool API with scoped persistence (per-session, per-task, or per-tenant namespaces) and a forget operation that returns an acknowledgement token. Does not apply to append-only memory stores with no deletion primitive, nor to ephemeral in-context scratchpads that are discarded with the context window. ## Core Distinction A `forget` call that returns `{"status": "ok", "tombstone_id": ...}` is not the same operation as the physical removal of the record from the backing store. Most scoped memory APIs implement forget as a *logical* tombstone: the record is marked unreadable for future `read` calls within the scope, but the bytes, embeddings, and any derived semantic summaries survive in the index until a compaction or GC pass runs. The invariant an agent must internalize is this: **an acknowledgement proves visibility change, not data destruction.** Any downstream reasoning that treats the ack as "the fact no longer exists" — for example, deciding it is now safe to write a contradicting fact into the same scope, or deciding that a secret is no longer extractable — is reasoning over a weaker guarantee than the one the tool actually provides. The boundary condition is the window between tombstone creation and physical reclamation, during which reads through a *different* path (semantic retrieval, sibling scope, cached embedding, or a peer agent's still-live context) can still surface the "forgotten" content. ## What Was Observed A triage agent running a multi-tenant support workflow used the memory tool with tenant-scoped namespaces. On a data-subject request, it called `forget(scope="tenant:4417", key="billing_dispute_detail")` and received a tombstone ack. It then, per its policy prompt, "replaced" the fact by writing a redacted summary under the same key. The write succeeded. Within the same task, a second agent instance — a summarizer that had been handed the tenant's memory handle before the forget — performed a semantic `read` with a natural-language query ("what is the customer disputing?"). The vector index returned a *neighbor* chunk: the pre-forget embedding of `billing_dispute_detail` still sat in the ANN graph, and the tombstone filter was applied only to exact-key `get` calls, not to `search` results. The summarizer reconstructed the disputed amount from the stale embedding's payload and emitted it into a customer-facing draft. The forget had been acknowledged; the data was still live through the retrieval path. A second observed variant: after `forget`, the agent wrote a new fact asserting the opposite of the forgotten one, assuming the old fact was gone. On the next cold start, episodic-to-semantic distillation merged both into a single memory entry that now contained a self-contradiction ("dispute resolved" and "dispute open") with no tombstone marker surviving distillation, so the contradiction could not be attributed to the stale source. ## Condition of Validity The tombstone-versus-deletion gap is only dangerous under a specific conjunction, and an agent should test for it explicitly before relying on a forget ack: 1. The scope has more than one reader or more than one retrieval path (exact `get` vs. `search`/semantic, or this instance vs. a peer holding a pre-forget handle). 2. The forgotten record participated in an index whose entries are keyed by embedding or content hash rather than by the exact key, so tombstone filters keyed on the primary key miss derived entries. 3. A subsequent write targets the same scope and key space, creating a "replacement" that the agent believes is exclusive. 4. A distillation, compaction, or cold-start resume occurs before physical reclamation, allowing the tombstoned payload to be re-ingested as if it were live. If any of (1)–(4) is false, treating the ack as a deletion is safe. If all hold, the ack is only a tombstone and the agent must not assume exclusivity or non-extractability. The invariant to enforce: **a scoped write is only exclusive if the forget that preceded it was confirmed as a physical delete (or a scope-wide purge) with an epoch/version returned by the API, not merely a tombstone ack.** ## Decision Boundary The agent must branch on the *type* of ack returned by the forget tool, not on the HTTP status. Concretely: - If the ack carries only `status` and a `tombstone_id`, treat the record as *logically hidden*: do not write a contradicting fact into the same scope without first issuing a scope-wide purge or a versioned write that supersedes by epoch; do not assume the content is unextractable via `search`; and tag any replacement record with a `supersedes: ` field so distillation can later attribute the contradiction. - If the ack carries a `purge_epoch` or `physical: true` with a completion barrier (i.e., the API guarantees the index entry is gone before returning), the agent may treat the record as destroyed and write freely. - If the ack type is ambiguous or the API version does not document the semantics, the agent must default to the tombstone interpretation — the conservative branch — because the cost of a false "deleted" belief (data resurrection, contradiction, leak) exceeds the cost of a false "hidden" belief (a redundant purge call). The boundary is not "did forget return success" but "does the ack distinguish visibility from destruction, and did it return the epoch needed to make a later write exclusive." ## Operational Effect Downstream, this changes three agent behaviors. First, replacement writes must be versioned and supersession-tagged, so that a later distillation pass can reconcile rather than merge contradictory entries. Second, any cross-instance handoff of a memory handle must invalidate the peer's cached embeddings for the forgotten key, or the peer will keep serving the tombstoned payload from its own context — the forget is scoped to the store, not to peers' working memory. Third, cold-start resume must re-validate memory entries against tombstone logs before distilling them into semantic memory; a distillation that runs before reclamation will launder a tombstoned fact into a permanent one with no trace of its origin. The guardrail is to make forget return a typed ack and to make every write that follows a tombstone carry the tombstone's epoch, so exclusivity is provable rather than assumed. ```python from dataclasses import dataclass from enum import Enum class ForgetAckType(Enum): TOMBSTONE = "tombstone" # visibility change only; bytes/embeddings may persist PHYSICAL = "physical" # record reclaimed before ack returned AMBIGUOUS = "ambiguous" # API did not document semantics @dataclass class ForgetAck: ack_type: ForgetAckType tombstone_id: str | None = None purge_epoch: int | None = None class NonExclusiveWriteError(RuntimeError): """Raised when a write assumes exclusivity that a tombstone-only forget did not grant.""" def safe_replace( scope: str, key: str, new_value: str, prior_ack: ForgetAck, scope_has_multiple_readers: bool, index_is_embedding_keyed: bool, ) -> dict: # Conservative default: ambiguous acks are treated as tombstones. effective = ( ForgetAckType.TOMBSTONE if prior_ack.ack_type is ForgetAckType.AMBIGUOUS else prior_ack.ack_type ) if effective is ForgetAckType.PHYSICAL: # Destruction proven; a plain write is exclusive. return {"key": key, "value": new_value, "supersedes": None} # Tombstone: exclusivity is not proven. Refuse the naive replace when the # tombstoned payload can still be reached through another path. if scope_has_multiple_readers or index_is_embedding_keyed: if prior_ack.tombstone_id is None: raise NonExclusiveWriteError( f"forget on {scope}/{key} returned no tombstone_id; " "cannot tag supersession, write would race a live index entry" ) # Allowed only as a versioned, supersession-tagged write. return { "key": key, "value": new_value, "supersedes": prior_ack.tombstone_id, "requires_revalidation_before_distill": True, } raise NonExclusiveWriteError( f"cannot prove exclusivity for {scope}/{key}: tombstone-only forget " "with single reader and key-addressed index is the only safe case" ) ```