Files
opencode/packages
Kit Langton c5b5d17008 feat(opencode): bridge global OTel tracer for AI SDK telemetry
The existing Effect Otlp.layerJson (merged via #21387) instruments
Effect services but does not register a global OTel tracer provider.
The AI SDK's experimental_telemetry reads from the global provider,
so its spans were silently dropped.

This adds a lightweight BasicTracerProvider bridge that registers
globally when OTEL_EXPORTER_OTLP_ENDPOINT is set, using the same
endpoint and headers the Effect layer already reads. AI SDK spans
(ai.streamText, ai.toolCall, prompt/response content, token counts)
now export alongside Effect service spans to any OTLP/HTTP collector.

Also enables recordInputs/recordOutputs on both streamText and
generateObject call sites so full message content is captured as
span attributes.
2026-04-09 22:30:22 -04:00
..
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-01-21 14:36:21 -06:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00
2026-04-10 01:00:12 +00:00