Merge pull request #3449 from kingster/telemetry-fix-system-message

fix: Record correct system_instruction in LLM spans for LLM services
This commit is contained in:
Mark Backman
2026-03-20 13:42:47 -04:00
committed by GitHub
4 changed files with 51 additions and 22 deletions

View File

@@ -0,0 +1 @@
- Renamed tracing span attributes to align with OpenTelemetry GenAI semantic conventions: `gen_ai.system` to `gen_ai.provider.name`, `system` to `gen_ai.system_instructions`, `gen_ai.usage.cache_read_input_tokens` to `gen_ai.usage.cache_read.input_tokens`, and `gen_ai.usage.cache_creation_input_tokens` to `gen_ai.usage.cache_creation.input_tokens`.

1
changelog/3449.fixed.md Normal file
View File

@@ -0,0 +1 @@
- Fixed stale `system_instruction` in LLM tracing spans by reading from `_settings.system_instruction` instead of the removed `_system_instruction` attribute.