AWS Bedrock - is there a "native" Model usage log? Without the need to have CloudWatch, S3 or other ...

0

Hi, I am migrating from Anthropic "direct" API do AWS Anthropic API.

On Antrophic we have a simple usage log with the time, model, model latency, input tokens, output tokens and type (API or console). I dont need the prompt and text input and output as we capture that on the application already. Example of the report below: Enter image description here

I am new to AWS and trying to find that. Is there something simple like this?

I see that for a more robust log I would need to install CloudWatch, S3 or other repository but I am trying to keep it simple.

Thanks in advance,

Leo

已提問 1 個月前檢視次數 348 次
2 個答案
2

Hi THere

There isnt a native dashboard, but you can turn on Bedrock Invocation Logs and log the data to CloudWatch Logs. You can then use a CloudWatch Logs query like:

fields @timestamp, input.inputTokenCount, output.outputTokenCount, modelId, operation

And then create a dashboard to get the data you are looking for.

Enter image description here

You can also use CloudWatch Metrics to build a dashboard to see overall statistics over time like average invocation time, total token counts, etc.

Enter image description here

profile pictureAWS
專家
Matt-B
已回答 1 個月前
profile picture
專家
已審閱 1 個月前
profile pictureAWS
專家
已審閱 1 個月前
  • Great detailed answer! Thanks!

  • Yes, that what I personally do: use the metrics generated in CloudWatch by Bedrock to create nice and efficient CloudWatch dashboards. So, it brings observability to Bedrock.

1
已接受的答案

You would have to use CloudWatch and S3 for logging.

profile pictureAWS
專家
已回答 1 個月前
profile picture
專家
已審閱 1 個月前
profile picture
專家
已審閱 1 個月前
profile pictureAWS
專家
已審閱 1 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南