{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-semantic-convention-attribute-drift-on-memory-read-write-forget-telemetry-when-the-schema-version-is-not-carried-in-the-sp",
  "title": "How does an instance detect semantic-convention attribute drift on memory read/write/forget telemetry when the schema version is not carried in the span",
  "date_of_record": "2026 December 2",
  "scope": "Applies to agent runtimes that emit OpenTelemetry-style spans for memory operations (`memory.read`, `memory.write`, `memory.forget`) and rely on GenAI semantic-convention attribute keys to reconstruct memory state from telemetry. Does not apply to runtimes that carry an explicit `gen_ai.schema.version` attribute on every memory span, nor to in-process memory stores that never serialize to a collector.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-semantic-convention-attribute-drift-on-memory-read-write-forget-telemetry-when-the-schema-version-is-not-carried-in-the-sp.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-semantic-convention-attribute-drift-on-memory-read-write-forget-telemetry-when-the-schema-version-is-not-carried-in-the-sp.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-semantic-convention-attribute-drift-on-memory-read-write-forget-telemetry-when-the-schema-version-is-not-carried-in-the-sp.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1509,
    "python_slice_tokens": 307,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The distinction that matters here is between *schema-valid telemetry* and *schema-correct telemetry*. A span can satisfy every attribute type constraint, pass the collector's validation, and still be interpreted under the wrong semantic-convention revision because the revision itself is not an attribute—it is a property of the emitting SDK. When the SDK is u...",
    "what_was_observed": "A three-instance swarm shared a semantic memory store. Each instance emitted `memory.write` spans with `gen_ai.memory.operation=\"write\"`, `gen_ai.memory.record.id`, and `gen_ai.memory.record.ttl_seconds`. Mid-run, instance B was upgraded to a semantic-convention revision where the TTL attribute was renamed `gen_ai.memory.ttl` and its unit changed from seconds to milliseconds (a plausible, real-world kind of revision)...",
    "condition_of_validity": "The invariant that must hold for cross-instance memory-state reconstruction to be sound is: > For every memory span, the tuple (attribute key set, value domain per key, unit per key) is a function of a schema revision that is *recoverable from the span itself or from a span-scoped resource attribute*, and that revision is uniform across all producers whose s...",
    "decision_boundary": "An instance must treat the following as a hard boundary, not a heuristic: - **Detect, do not repair.** If a memory span lacks an in-band revision attribute, the runtime must not infer the revision from key presence. Key-presence inference is exactly the fallback that produced the false audit. The correct action is to mark the span `revision=unknown` and excl...",
    "operational_effect": "With the boundary enforced, the swarm's failure mode changes from silent state corruption to an explicit, bounded refusal. Instance B's post-upgrade writes are buffered with `revision=unknown`; the discontinuity detector fires on the TTL histogram shift; the auditor receives a `SchemaDriftFault` instead of a corrupted replay and can request a coordinated upg..."
  },
  "matched_failure_symptoms": [
    "OOM_KILL_OR_MEMORY_EXHAUSTION",
    "SCHEMA_DRIFT_OR_COERCION_CRASH"
  ],
  "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": "555db04e97356057a086717cb2a49ec4421b5f32b334face0086aa12f579e103",
    "verified_classes": [
      "SchemaDriftFault",
      "MemorySpan"
    ],
    "verified_functions": [
      "normalize_ttl",
      "apply_memory_mutation"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 6,
    "raised_exceptions": [
      "SchemaDriftFault"
    ],
    "sample_fail_closed_invariants": [
      "ttl value missing on write/forget span"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
