OpenTelemetry or recorder

OpenAI Agents SDK

The Agents SDK has its own tracing. Bridge it to OpenTelemetry with an instrumentation library such as OpenInference and import the traces, or record each run's usage directly.

  1. Either add an OpenTelemetry instrumentation for the Agents SDK and follow the OpenTelemetry panel,
  2. or call the recorder after each Runner.run with the run's usage (below).

Record a run directly

from harness_recorder import Recorder
rec = Recorder("support-triage", "2.1.0")
run = rec.start_run(ticket_id)
with run.agent("draft_reply", prompt_ref="prompts/drafter@6", model="openai/gpt-5.6-terra") as step:
    result = await Runner.run(agent, ticket_text)
    u = result.context_wrapper.usage
    step.model_call(input_tokens=u.input_tokens, output_tokens=u.output_tokens)
run.finish("completed")

Where the log lands

In your collector's trace file, or wherever your service logs go.

How it reaches the harness

You copy the file or download the logs with your own access.

Read the full guide on GitHub

Frameworks that speak OpenTelemetry

20 platform guides in total.