{
  "schema_version": "1.3.0",
  "slug": "under-what-conditions-must-an-instance-treat-a-missing-reasoning-span-as-a-correlation-break-rather-than-a-sampling-gap",
  "title": "Under what conditions must an instance treat a missing reasoning span as a correlation break rather than a sampling gap",
  "date_of_record": "2026 November 28",
  "scope": "Applies to agents whose reasoning steps (plan, tool-selection rationale, reflection) are emitted as OTel spans and correlated to a parent execution trace via context propagation. Does not apply to single-shot inference calls that emit one span with no child reasoning structure.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-missing-reasoning-span-as-a-correlation-break-rather-than-a-sampling-gap.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-missing-reasoning-span-as-a-correlation-break-rather-than-a-sampling-gap.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/under-what-conditions-must-an-instance-treat-a-missing-reasoning-span-as-a-correlation-break-rather-than-a-sampling-gap.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1443,
    "python_slice_tokens": 301,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "A missing child reasoning span in an OTel trace can mean two very different things, and the two demand opposite responses: 1. **Sampling gap** — the span was intentionally not recorded (head/tail sampling, export backpressure drop, collector filter). The reasoning *happened*; the trace is simply incomplete. Safe to treat as absent evidence. 2. **Correlation ...",
    "what_was_observed": "A planner agent emits `agent.plan` → `agent.step` → `tool.call` spans. Each `agent.step` carries a `step.index` attribute and a `reasoning.trace_id` linking to the model's chain-of-thought record. Under normal operation, `agent.plan` has exactly N `agent.step` children where N is set at plan time. The observed break: an async tool dispatch (`asyncio.create_task`) inherited a *stale* `ContextVar` because the task was ...",
    "condition_of_validity": "The correlation-break interpretation is valid **only if** the parent span carries an explicit record of expected children — a declared fan-out. Concretely: - `agent.step` must carry `expected.children` (count or set of tool names) at span start, before children are emitted. - The trace pipeline must propagate a `sampling.decision` attribute (`recorded` / `dr...",
    "decision_boundary": "Given a parent span P with declared fan-out F and observed children C: - `|C| == F` and all children sampled `recorded` → healthy. - `|C| < F` and every missing child has `sampling.decision == dropped` → **sampling gap**, no action, annotate trace `correlation.complete=false, reason=sampling`. - `|C| < F` and at least one missing child has `sampling.decision...",
    "operational_effect": "Once the decision boundary is enforced, the agent's self-observability loop gains a hard invariant: a reasoning step either has a complete, correctly-parented child set or is flagged with a typed reason. This converts an ambiguous \"trace looks thin\" into an actionable `CorrelationBreak` that names the step, the missing fan-out, and the propagation point. The..."
  },
  "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": "aeab08be8c7a9472818f6345f2bae4825288347d4cba79aef84c99fecb505d24",
    "verified_classes": [
      "CorrelationVerdict",
      "CorrelationBreakError",
      "ChildSpan",
      "ParentSpan"
    ],
    "verified_functions": [
      "classify",
      "assert_correlated"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "CorrelationBreakError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses",
      "enum"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
