@@ -156,7 +156,7 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
156156 : [ "" , "" ] ;
157157
158158 attributes = {
159- [ SpanAttributes . LLM_VENDOR ] : vendor ,
159+ [ SpanAttributes . LLM_SYSTEM ] : vendor ,
160160 [ SpanAttributes . LLM_REQUEST_MODEL ] : model ,
161161 [ SpanAttributes . LLM_RESPONSE_MODEL ] : model ,
162162 [ SpanAttributes . LLM_REQUEST_TYPE ] : LLMRequestTypeValues . COMPLETION ,
@@ -197,7 +197,7 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
197197 ? ( span [ "attributes" ] as Record < string , any > )
198198 : { } ;
199199
200- if ( SpanAttributes . LLM_VENDOR in attributes ) {
200+ if ( SpanAttributes . LLM_SYSTEM in attributes ) {
201201 if ( ! ( result . body instanceof Object . getPrototypeOf ( Uint8Array ) ) ) {
202202 const rawRes = result . body as AsyncIterable < bedrock . ResponseStream > ;
203203
@@ -234,7 +234,7 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
234234 }
235235
236236 let responseAttributes = this . _setResponseAttributes (
237- attributes [ SpanAttributes . LLM_VENDOR ] ,
237+ attributes [ SpanAttributes . LLM_SYSTEM ] ,
238238 parsedResponse ,
239239 true ,
240240 ) ;
@@ -265,7 +265,7 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
265265 const parsedResponse = JSON . parse ( jsonString ) ;
266266
267267 const responseAttributes = this . _setResponseAttributes (
268- attributes [ SpanAttributes . LLM_VENDOR ] ,
268+ attributes [ SpanAttributes . LLM_SYSTEM ] ,
269269 parsedResponse ,
270270 ) ;
271271
@@ -289,8 +289,8 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
289289 switch ( vendor ) {
290290 case "ai21" : {
291291 return {
292- [ SpanAttributes . LLM_TOP_P ] : requestBody [ "topP" ] ,
293- [ SpanAttributes . LLM_TEMPERATURE ] : requestBody [ "temperature" ] ,
292+ [ SpanAttributes . LLM_REQUEST_TOP_P ] : requestBody [ "topP" ] ,
293+ [ SpanAttributes . LLM_REQUEST_TEMPERATURE ] : requestBody [ "temperature" ] ,
294294 [ SpanAttributes . LLM_REQUEST_MAX_TOKENS ] : requestBody [ "maxTokens" ] ,
295295 [ SpanAttributes . LLM_PRESENCE_PENALTY ] :
296296 requestBody [ "presencePenalty" ] [ "scale" ] ,
@@ -309,9 +309,9 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
309309 }
310310 case "amazon" : {
311311 return {
312- [ SpanAttributes . LLM_TOP_P ] :
312+ [ SpanAttributes . LLM_REQUEST_TOP_P ] :
313313 requestBody [ "textGenerationConfig" ] [ "topP" ] ,
314- [ SpanAttributes . LLM_TEMPERATURE ] :
314+ [ SpanAttributes . LLM_REQUEST_TEMPERATURE ] :
315315 requestBody [ "textGenerationConfig" ] [ "temperature" ] ,
316316 [ SpanAttributes . LLM_REQUEST_MAX_TOKENS ] :
317317 requestBody [ "textGenerationConfig" ] [ "maxTokenCount" ] ,
@@ -328,9 +328,9 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
328328 }
329329 case "anthropic" : {
330330 return {
331- [ SpanAttributes . LLM_TOP_P ] : requestBody [ "top_p" ] ,
331+ [ SpanAttributes . LLM_REQUEST_TOP_P ] : requestBody [ "top_p" ] ,
332332 [ SpanAttributes . LLM_TOP_K ] : requestBody [ "top_k" ] ,
333- [ SpanAttributes . LLM_TEMPERATURE ] : requestBody [ "temperature" ] ,
333+ [ SpanAttributes . LLM_REQUEST_TEMPERATURE ] : requestBody [ "temperature" ] ,
334334 [ SpanAttributes . LLM_REQUEST_MAX_TOKENS ] :
335335 requestBody [ "max_tokens_to_sample" ] ,
336336
@@ -350,9 +350,9 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
350350 }
351351 case "cohere" : {
352352 return {
353- [ SpanAttributes . LLM_TOP_P ] : requestBody [ "p" ] ,
353+ [ SpanAttributes . LLM_REQUEST_TOP_P ] : requestBody [ "p" ] ,
354354 [ SpanAttributes . LLM_TOP_K ] : requestBody [ "k" ] ,
355- [ SpanAttributes . LLM_TEMPERATURE ] : requestBody [ "temperature" ] ,
355+ [ SpanAttributes . LLM_REQUEST_TEMPERATURE ] : requestBody [ "temperature" ] ,
356356 [ SpanAttributes . LLM_REQUEST_MAX_TOKENS ] : requestBody [ "max_tokens" ] ,
357357
358358 // Prompt & Role
@@ -367,8 +367,8 @@ export class BedrockInstrumentation extends InstrumentationBase<any> {
367367 }
368368 case "meta" : {
369369 return {
370- [ SpanAttributes . LLM_TOP_P ] : requestBody [ "top_p" ] ,
371- [ SpanAttributes . LLM_TEMPERATURE ] : requestBody [ "temperature" ] ,
370+ [ SpanAttributes . LLM_REQUEST_TOP_P ] : requestBody [ "top_p" ] ,
371+ [ SpanAttributes . LLM_REQUEST_TEMPERATURE ] : requestBody [ "temperature" ] ,
372372 [ SpanAttributes . LLM_REQUEST_MAX_TOKENS ] : requestBody [ "max_gen_len" ] ,
373373
374374 // Prompt & Role
0 commit comments