Skip to content

[backend] OTel trace export arc — PR 2: child spans + spec/39 LOCK + P2 polish #374

@dep0we

Description

@dep0we

Continuation of the OTel trace export arc started in #341 (PR 1).

PR 1 shipped (#341)

  • atomic_agents.tracing module — off-by-default seam, [otel] extra, OTLP/HTTP exporter.
  • agent.call() parent span (atomic_agents.call) with cost/token/outcome attributes, ended on all exit paths via idempotent non-throwing finalizer.
  • DRAFT spec/39 (253 lines, 9 MUSTs).

Deferred to this PR (PR 2 of the arc)

  1. Child spans. gen_ai.client.chat (LLM), tool, helper, delegate spans — constants are already declared in tracing.py (SPAN_LLM_CALL, SPAN_TOOL_CALL, SPAN_HELPER_CALL, SPAN_DELEGATE) and the gen_ai.* semconv attributes are reserved, but the spans are not yet emitted. Wire them as children of the parent atomic_agents.call span, carrying parent_run_id parity with the JSONL audit rollup (Principle 5).
  2. spec/39 LOCK. Run the LOCK ceremony (drift audit per [[feedback_lock_ceremony_drift_gate]]) once child spans match the spec and tests pass — flip DRAFT → LOCKED.
  3. P2 polish carried from PR 1's converged round-4 review — non-blocking style/doc-completeness items (ruff import-ordering noqa hygiene in tracing.py; spec/39 doc-completeness passes). Fold into the LOCK drift audit.

Context

PR 1 converged directly in arc-execute (round 4, hardened graded gate) — first build to converge without a separate arc-finish pass. Residual items above were classified non-blocking P2 and carried here per the standing graded-gate model (gate on P0/P1, report P2).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestspecImplementation of an Atomic Agents spec doc

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions