{
  "schema_version": "1.3.0",
  "slug": "why-does-an-instance-lose-memory-write-provenance-when-otel-memory-tool-spans-drop-the-forget-semantic-convention",
  "title": "Why does an instance lose memory-write provenance when OTel memory tool spans drop the `forget` semantic convention",
  "date_of_record": "2026 November 30",
  "scope": "Applies to agent runtimes that emit OpenTelemetry spans for memory tool operations (`read`, `write`, `forget`) through a semantic-convention-mapping exporter, where downstream provenance reconstruction (audit, replay, or distillation) consumes the exported span set rather than the live agent state. Does not apply to systems that persist memory mutations in a transactional store independent of telemetry, nor to exporters that treat memory operations as opaque custom spans with no convention mapping.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-memory-write-provenance-when-otel-memory-tool-spans-drop-the-forget-semantic-convention.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-memory-write-provenance-when-otel-memory-tool-spans-drop-the-forget-semantic-convention.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/why-does-an-instance-lose-memory-write-provenance-when-otel-memory-tool-spans-drop-the-forget-semantic-convention.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1927,
    "python_slice_tokens": 418,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not that a `forget` span is missing from the trace. The failure is that the **exporter's convention-coverage table treats `forget` as a degenerate `write`**, so a deletion is emitted with the same `memory.operation` attribute value (`write`) and the same payload shape as an insertion. Downstream consumers that reconstruct episodic-to-semantic ...",
    "what_was_observed": "A distillation job consumed 14,000 memory-tool spans over a 72-hour window and reconstructed a semantic memory graph. Post-hoc comparison against the authoritative store showed 312 addresses where the reconstructed graph asserted a fact that the store had retracted. Trace inspection on a sample of 40: 1. Agent asserts fact `F` at address `A` — span emitted with `memory.operation=write`, `memory.address=A`, `memory.co...",
    "condition_of_validity": "The guardrail holds only under a specific condition: **the exporter must carry a total, injective mapping from the runtime's memory-tool operation set onto `memory.operation` enum values, and the enum must be closed under the algebra's non-commutative pairs.** Concretely: - The mapping is *total*: every operation the runtime can emit (including `forget`, `ex...",
    "decision_boundary": "The boundary between \"safe to coerce\" and \"must reject\" is determined by whether the operation participates in a non-commutative pair with an already-mapped operation. - **Coerce** an unmapped operation `op` to an existing enum value `v` only if `op` commutes with every operation already mapped to `v` in final-state terms. `read`→`read` is safe (reads don't ...",
    "operational_effect": "With the total-injective mapping enforced, replay of the 14,000-span window against the authoritative store produced zero false-live addresses. The cost was 4,100 spans that the previous fallback had silently coerced now emitted with `memory.operation=forget` and a `memory.tombstone_target` attribute carrying the address and content-hash of the retracted fac..."
  },
  "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": "069d73793facfcfb0e1c0e9527d2130cf023ae9366759923c2966552763b9c38",
    "verified_classes": [
      "ConventionCoverageError",
      "MemoryOp"
    ],
    "verified_functions": [
      "build_convention_map",
      "export_memory_span"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ConventionCoverageError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
