{
"resourceSpans": [{
"resource": {
"attributes": [{
"key": "service.name",
"value": { "stringValue": "your-service-name" }
}]
},
"scopeSpans": [{
"scope": {
"name": "openai",
"version": "1.0.0"
},
"spans": [{
"name": "OpenAI ChatCompletion",
"kind": 2, // SpanKind.CLIENT
"startTimeUnixNano": "1234567890000000000",
"endTimeUnixNano": "1234567891000000000",
"traceId": "a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6",
"spanId": "a1b2c3d4e5f6g7h8",
"attributes": [{
"key": "llm.vendor",
"value": { "stringValue": "openai" }
}, {
"key": "llm.request.model",
"value": { "stringValue": "gpt-3.5-turbo" }
}, {
"key": "llm.request.messages",
"value": { "stringValue": "[{\"role\": \"user\", \"content\": \"Hello\"}]" }
}, {
"key": "llm.path",
"value": { "stringValue": "/v1/chat/completions" }
}, {
"key": "llm.request.temperature",
"value": { "intValue": 0.7 }
}, {
"key": "llm.request.max_tokens",
"value": { "intValue": 150 }
}, {
"key": "llm.usage.prompt_tokens",
"value": { "intValue": 10 }
}, {
"key": "llm.usage.completion_tokens",
"value": { "intValue": 15 }
}, {
"key": "llm.usage.total_tokens",
"value": { "intValue": 25 }
}]
}]
}]
}]
}