getsentry / getsentry/sentry-javascript

Update shared gen_ai attribute constants & utilities

Đang mở
#20,577 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
javascript Task
Ngôn ngữ chính
TypeScript
Star
8.7k
Fork
1.8k
Merge trung bình
1 ngày 17 giờ
Pull request đã merge (30 ngày)
515

Mô tả

Update the shared attribute constants and utilities to align with [RFC #153](). This is the foundation for all per-provider work.

### New constants to add

- [ ] `gen_ai.provider.name` (replaces `gen_ai.system`)
- [ ] `gen_ai.tool.definitions` (replaces `gen_ai.request.available_tools`)
- [ ] `gen_ai.tool.call.arguments` (replaces `gen_ai.tool.input`)
- [ ] `gen_ai.tool.call.result` (replaces `gen_ai.tool.output`)
- [ ] `gen_ai.response.time_to_first_token`
- [ ] `gen_ai.embeddings.dimension.count`
- [ ] `gen_ai.usage.output_tokens.reasoning`
- [ ] `gen_ai.request.seed`

### Constants to deprecate

- [ ] `gen_ai.system`
- [ ] `gen_ai.prompt`
- [ ] `gen_ai.request.available_tools`
- [ ] `gen_ai.response.text`
- [ ] `gen_ai.response.tool_calls`
- [ ] `gen_ai.tool.input`
- [ ] `gen_ai.tool.output`
- [ ] `gen_ai.usage.cache_creation_input_tokens`
- [ ] `gen_ai.usage.cache_read_input_tokens`

### Shared utilities

- [ ] Update `setTokenUsageAttributes()` to use new token attribute names
- [ ] Update message format utilities (content → parts)
- [ ] Update message truncation and media stripping helpers

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.