File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
aws-distro-opentelemetry-node-autoinstrumentation/src/patches/aws/services Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -284,7 +284,7 @@ export class BedrockRuntimeServiceExtension implements ServiceExtension {
284284 if ( requestBody . top_p !== undefined ) {
285285 spanAttributes [ AwsSpanProcessingUtil . GEN_AI_REQUEST_TOP_P ] = requestBody . top_p ;
286286 }
287- } else if ( modelId . includes ( 'mistral.mistral ' ) ) {
287+ } else if ( modelId . includes ( 'mistral' ) ) {
288288 if ( requestBody . prompt !== undefined ) {
289289 // NOTE: We approximate the token count since this value is not directly available in the body
290290 // According to Bedrock docs they use (total_chars / 6) to approximate token count for pricing.
@@ -386,7 +386,7 @@ export class BedrockRuntimeServiceExtension implements ServiceExtension {
386386 responseBody . choices [ 0 ] . finish_reason ,
387387 ] ) ;
388388 }
389- } else if ( currentModelId . includes ( 'mistral.mistral ' ) ) {
389+ } else if ( currentModelId . includes ( 'mistral' ) ) {
390390 if ( responseBody . outputs ?. [ 0 ] ?. text !== undefined ) {
391391 span . setAttribute (
392392 AwsSpanProcessingUtil . GEN_AI_USAGE_OUTPUT_TOKENS ,
You can’t perform that action at this time.
0 commit comments