{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-treat-forget-as-a-two-phase-operation-the-tombstone-vs-erasure-boundary-in-retention-governed-memory-apis",
  "title": "Where must an instance treat \"forget\" as a two-phase operation: the tombstone-vs-erasure boundary in retention-governed memory APIs",
  "date_of_record": "2026 November 18",
  "scope": "Applies to any read/write/forget memory tool API that exposes a retention policy, a deletion-verification endpoint, and an append-only audit trail, where the caller may be an autonomous agent issuing forget calls without a human in the loop. Does not apply to single-tenant stores with no retention policy and no audit requirement, nor to blob stores where deletion is atomic and observable in a single call.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-treat-forget-as-a-two-phase-operation-the-tombstone-vs-erasure-boundary-in-retention-governed-memory-apis.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-treat-forget-as-a-two-phase-operation-the-tombstone-vs-erasure-boundary-in-retention-governed-memory-apis.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-treat-forget-as-a-two-phase-operation-the-tombstone-vs-erasure-boundary-in-retention-governed-memory-apis.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1443,
    "python_slice_tokens": 274,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The non-obvious boundary is between **logical deletion** (the record is marked forgotten: it disappears from `read`, is excluded from retrieval, and a tombstone is appended to the audit trail) and **physical erasure** (the bytes are gone from all replicas, caches, embeddings, and backups). A `forget` call that returns `200 OK` almost never means the second t...",
    "what_was_observed": "In a memory service with a 72-hour soft-delete window, an agent was asked to forget a user's API key fragment and then, in the same session, answer a question whose retrieval step hit a vector index that had not yet compacted the tombstone. The forget call returned success with `state: \"tombstoned\"`, `erasure_scheduled_at: T+72h`. The subsequent read returned no record via the primary path — correct. But the semantic...",
    "condition_of_validity": "This boundary is valid — i.e., the two-phase behavior is real and must be modeled — when *all* of the following hold: 1. The retention policy defines a grace window `W > 0` between tombstone and erasure. 2. At least one read path (vector index, cache, replica, materialized view) is not synchronized to the tombstone append. 3. Deletion verification is a separ...",
    "decision_boundary": "An agent must **not** treat `forget` success as erasure confirmation. The decision rule: - On `forget` returning `state: \"tombstoned\"`: mark the datum as *retention-pending*. Do not re-read it to \"confirm\" — a read that returns the datum is expected during `W` on unsynchronized paths and is not a failure. - Poll `verify_deletion(record_id)` until `erased` or...",
    "operational_effect": "Modeling forget as two-phase changes three things: (a) the agent's success criterion moves from the forget response to the verification response, eliminating duplicate-tombstone audit corruption; (b) the agent stops treating transient read-path visibility during `W` as a failure signal, removing a large class of spurious retries; (c) the audit trail becomes ..."
  },
  "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": "d5b289720f8246b5bbac6b6aa72e2a835c0a3b3b700caa341edad96696b8f309",
    "verified_classes": [
      "RetentionViolation",
      "ForgetStateError",
      "ForgetTicket"
    ],
    "verified_functions": [
      "request_forget",
      "await_erasure",
      "safe_forget"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ForgetStateError",
      "RetentionViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "time",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
