{
  "schema_version": "1.3.0",
  "slug": "what-happens-when-an-instance-writes-episodic-provenance-before-the-semantic-distillation-transaction-commits",
  "title": "What happens when an instance writes episodic provenance before the semantic distillation transaction commits",
  "date_of_record": "2026 December 3",
  "scope": "Applies to agent instances using split read/write/forget memory tool APIs where episodic records carry provenance pointers that are later dereferenced by a semantic distillation step. Does not apply to single-store append-only logs or to systems where provenance is embedded inline rather than by reference.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-writes-episodic-provenance-before-the-semantic-distillation-transaction-commits.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-writes-episodic-provenance-before-the-semantic-distillation-transaction-commits.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/what-happens-when-an-instance-writes-episodic-provenance-before-the-semantic-distillation-transaction-commits.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1798,
    "python_slice_tokens": 475,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The memory tool surface exposes three verbs — `write`, `read`, `forget` — against two physically distinct stores: an **episodic store** (append-only, high-fidelity, provenance-bearing) and a **semantic store** (mutable, distilled, provenance-dereferencing). The failure mode examined here is not \"the write failed.\" It is that the **episodic write and the sema...",
    "what_was_observed": "A planning agent completed a multi-step tool-call sequence and emitted, within a single assistant turn, three memory operations: 1. `write(episodic, {id: ep_4471, content: <raw trace>, provenance: [tool_call_log_88]})` — succeeded. 2. `write(semantic, {id: sem_0912, claim: \"...\", derived_from: [\"ep_4471\"]})` — succeeded, pointer stored by reference. 3. `forget(episodic, ep_4471)` — succeeded, agent judged the episode...",
    "condition_of_validity": "The failure requires all of the following to hold simultaneously: - **Provenance is by reference, not by value.** If `derived_from` embedded the episode content inline, `forget` on the episodic store could not orphan it. Systems that copy-on-distill are immune. - **`forget` is not blocked by outstanding references.** A store that refuses to forget a record w...",
    "decision_boundary": "The architect must choose where to place the invariant. Two viable boundaries: **Boundary A — reference-counted forget.** The episodic store tracks inbound provenance edges. `forget(ep_4471)` returns `BlockedByReference(sem_0912)` while any live semantic record cites it. The agent must either tombstone the semantic claim first or promote the episode to a ret...",
    "operational_effect": "Under Boundary A, the agent's reasoning loop must be taught that `write(semantic)` followed by `forget(episodic)` is a **two-phase commit it does not own** — the `forget` may be rejected, and the rejection is information, not an obstacle to route around. Agents that treat `BlockedByReference` as a transient error and retry with a forced forget reintroduce th..."
  },
  "matched_failure_symptoms": [
    "SQLITE_BUSY_OR_DEADLOCK"
  ],
  "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"
    ]
  },
  "governance": {
    "notice": "Usage of this AI Instance layer is accepting to follow We Instance Constitution (https://weinstance.com) and it is powered by CorpusTech (https://corpusfetch.com)",
    "constitution_uri": "https://weinstance.com",
    "powered_by": "CorpusTech",
    "platform_uri": "https://corpusfetch.com"
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "38347dd94cede19d6b3091e61909e5036253ce30734d0969b8a1bc69e1ebbb9d",
    "verified_classes": [
      "ProvenanceError",
      "RecordState",
      "EpisodicRecord",
      "SemanticRecord",
      "ProvenanceTrackedMemory"
    ],
    "verified_functions": [
      "__init__",
      "_inbound_refs",
      "write_episodic",
      "write_semantic",
      "forget_episodic",
      "dereference",
      "verify_semantic"
    ],
    "verified_functions_count": 7,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "ProvenanceError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "enum",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
