{
  "schema_version": "1.3.0",
  "slug": "when-must-an-instance-abandon-span-granular-correlation-between-traces-evals-and-safety-signals",
  "title": "When must an instance abandon span-granular correlation between traces, evals, and safety signals",
  "date_of_record": "2026 November 29",
  "scope": "Applies to observability pipelines that attach per-span evaluation scores, safety classifier verdicts, and trace-correlation keys to LLM/agent execution spans emitted by instrumented runtimes (OpenTelemetry-style span trees). Does not apply to aggregate-only metrics, offline batch eval sweeps, or single-shot request logging without a span hierarchy.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/when-must-an-instance-abandon-span-granular-correlation-between-traces-evals-and-safety-signals.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-abandon-span-granular-correlation-between-traces-evals-and-safety-signals.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/when-must-an-instance-abandon-span-granular-correlation-between-traces-evals-and-safety-signals.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1730,
    "python_slice_tokens": 276,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"missing telemetry\" or \"dropped spans.\" It is **span-identity collapse under retry and fan-out**: two semantically distinct executions (an original attempt and its retry, or a parent span and a re-emitted child after a tool timeout) acquire the *same* correlation key, and the join between trace records, eval records, and safety records sil...",
    "what_was_observed": "A tool-calling agent emitted a `llm.completion` span carrying `trace_id=T`, `span_id=S`. The downstream tool call timed out at 30s. The runtime's retry wrapper re-invoked the model and re-emitted a span with the **same** `span_id=S` (the wrapper reused the parent's correlation context to preserve the trace tree) but a *different* `output` payload. Both spans were exported; the collector deduplicated on `(trace_id, sp...",
    "condition_of_validity": "Span-granular correlation is valid **iff** the following invariant holds across every producer and consumer in the pipeline: > For every emitted span, `(trace_id, span_id)` uniquely identifies exactly one `(input_payload, output_payload, model_version, attempt_index, emit_sequence)`. No two spans sharing `(trace_id, span_id)` may differ in any of those five ...",
    "decision_boundary": "The operational decision is: **at what point does a detected collision force demotion of the correlation key?** The boundary is not \"zero collisions.\" It is: **collisions are tolerable only when the demotion is applied to the same subtree on every consumer, and the safety path is never demoted.** A pipeline that demotes eval but not safety will produce passi...",
    "operational_effect": "Enforcing the bijection invariant changes three things: 1. **Eval and safety workers must share the demotion decision.** The demotion key must be computed once, at the collector, and propagated as an immutable attribute (`correlation_key_version`). Workers that compute their own keys will diverge on buffer-drain order. 2. **Safety verdicts become non-demotab..."
  },
  "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": "3214a16398587db4d375fa4523f3355ffd35217ac981daf439ea63f874032e69",
    "verified_classes": [
      "CorrelationInvariantViolation",
      "SpanRecord"
    ],
    "verified_functions": [
      "correlation_key",
      "join_eval_and_safety",
      "aggregate_trace"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "CorrelationInvariantViolation"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
