Otel Agent Trace Connector banner
nijave nijave

Otel Agent Trace Connector

Development community

Description

OpenTelemetry Collector connector for normalized Codex and Claude Code traces

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

Coding-agent OpenTelemetry connector

An organization adopting AI coding agents receives telemetry in as many shapes as it runs agents. This connector normalizes those shapes into one canonical trace vocabulary so the same queries measure token usage — and the cost derived from it — across every agent. Latency and tool activity ride the same spans. Prompt text, tool arguments, and tool output never enter canonical output, so usage visibility does not require collecting what developers type. [docs/design.md](docs/design.md) records the use case and design goals.

This repository provides an external OpenTelemetry Collector connector and an OCB-built distribution for coding-agent traces:

  • Codex: correlates structured codex.* OTLP logs into one canonical trace per user turn.
  • Cursor: correlates native cursor.telemetry OTLP logs (Enterprise beta, metrics + logs only) into one canonical trace per activity burst, keyed on cursor.conversation.id. Chat spans carry per-request token usage; the wire reports tool calls only as metrics without correlation IDs, so canonical traces have no execute_tool children.
  • OpenCode: renames its native Vercel AI SDK spans (ai.streamText, ai.streamText.doStream, ai.toolCall) into one invoke_agent opencode canonical trace per model step, dropping internal instrumentation spans and all content attributes.
  • GitHub Copilot: normalizes native GenAI-semconv traces from Copilot CLI and VS Code Chat (invoke_agent/chat/execute_tool) through the shared GenAI-semconv edge
  • Claude Code: preserves its native span hierarchy and normalizes the interaction, LLM, and tool span names and attributes into the same canonical vocabulary.
  • GenAI semconv sources: normalizes native traces from opentelemetry-instrumentation-openai-v2 (both semconv modes), direct opentelemetry-util-genai users, and the Strands Agents SDK into the same canonical vocabulary, stripping prompt/complet