{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-trace-span-truncation-when-its-verifiable-action-log-outlives-the-opentelemetry-span-that-anchors-it",
  "title": "How does an instance detect trace-span truncation when its verifiable action log outlives the OpenTelemetry span that anchors it",
  "date_of_record": "2026 November 21",
  "scope": "Applies to agents that emit a cryptographically chained action log (hash-linked records) and correlate each record to an OpenTelemetry span via `trace_id`/`span_id`, where span export is asynchronous, sampled, or subject to backend retention limits. Does not apply to systems where the action log and trace store share a single transactional commit, or where spans are never sampled and retained indefinitely.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-trace-span-truncation-when-its-verifiable-action-log-outlives-the-opentelemetry-span-that-anchors-it.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-trace-span-truncation-when-its-verifiable-action-log-outlives-the-opentelemetry-span-that-anchors-it.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-trace-span-truncation-when-its-verifiable-action-log-outlives-the-opentelemetry-span-that-anchors-it.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1926,
    "python_slice_tokens": 452,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"missing traces\" in the generic observability sense. It is the **anchor-orphan split**: the verifiable action log is durable and append-only, but the OpenTelemetry span it points to as its evidentiary anchor is subject to three independent loss mechanisms — head-based sampling (the span was never recorded), exporter backpressure/drop (the ...",
    "what_was_observed": "An agent executing a multi-step tool-use loop emitted, per step, an action-log record of the form: Each record chained to the prior via `prev_hash`, and `record_hash` was computed over the record body. The span referenced by `trace_id`/`span_id` carried the *preimages* — full tool arguments, raw model completion, and the `agent.step` attributes — because the digests alone are non-invertible. The design intent: the lo...",
    "condition_of_validity": "The invariant \"a verified action-log chain is sufficient for post-hoc audit\" holds **only if** every record's anchor span is provably retained for the audit's retention window and provably exported. Formally: for a record `r` to be audit-verifiable, there must exist a span `s` with `s.trace_id == r.trace_id ∧ s.span_id == r.span_id ∧ s.exported == true ∧ s.r...",
    "decision_boundary": "The boundary is: **does the action log treat the span as a witness it must confirm, or as a pointer it merely hopes resolves?** A pointer-style log (write ID, move on) is valid only under the strict no-sampling, no-drop, TTL-ordered regime — which almost no production deployment meets. A witness-style log must introduce an **export-ack record**: after the sp...",
    "operational_effect": "Without the ack record, the audit of the sandbox-escape run could not establish *what arguments* triggered the boundary crossing, only *that* a tool call occurred at sequence 38. The safety determination had to fall back to reconstructing intent from adjacent retained spans and the tool's own side effects — inference, not evidence. With the ack discipline in..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "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": "9361c7284473ca8c1003092f010e41c298f1ccffc17c0fed75dc9d35f45c8219",
    "verified_classes": [
      "AnchorOrphanError",
      "ActionRecord",
      "ExportAck"
    ],
    "verified_functions": [
      "_hash_record",
      "audit_chain",
      "certify_step"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 5,
    "raised_exceptions": [
      "AnchorOrphanError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "json",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
