GenAI semantic conventions

OpenTelemetry's standard attribute names, spans, metrics and events for generative AI calls, such as gen_ai.operation.name and gen_ai.usage.input_tokens.

In more detail

They live in their own repository and are still at Development status, so names can change: pin the version you follow. Required attributes are the operation and provider names; the request model is conditionally required and token usage recommended, while prompt and reply content are opt-in because they may hold personal data. Input token counts include cached tokens.

Related terms

Taught in

References

Certification courses