Hi! I am connected to a mastra app that makes calls to AWS bedrock and I am currently not getting any pricing data. Is the fix as simple as providing AWS creds for bedrock to phoenix to make the data available or is there more to it? Thanks a lot!
Providing AWS credentials to Phoenix enables tracing and evaluation of Bedrock calls, but there is no mention in the documentation that Phoenix or its Bedrock instrumentation collects or displays AWS pricing data. The available integrations focus on observability, tracing, and evaluation of LLM calls, not on retrieving or surfacing cost or pricing information from AWS Bedrock APIs or billing endpoints. Therefore, simply providing AWS credentials will not make pricing data available in Phoenix鈥攖his functionality is not supported or documented as of now.If you need pricing data, you would need to retrieve it separately using AWS billing APIs or the AWS console, as Phoenix does not natively support this feature for Bedrock integrations according to the official documentation and integration guides (Amazon Bedrock Tracing, OpenInference Bedrock Instrumentation).Would you like more detail on how to set up tracing or evaluation with Bedrock in Phoenix?Sources: - OpenInference Bedrock Instrumentation - Amazon Bedrock Tracing
馃挕聽Hint: Mention RunLLM in the thread for followups.
Can you share the model name present in your span attributes for one of the bedrock spans? Also, are token counts appearing as well?
I get token counts. Let me see what I can do for adding a model to the span. I just wasn't sure where the missing link in the chain was
seems like that information is already available
{
"ai": {
"model": {
"id": "us.anthropic.claude-3-7-sonnet-20250219-v1:0",
"provider": "amazon-bedrock"
},
"usage": {
"promptTokens": 3444,
"completionTokens": 130
},If a model isn't there already then we have a problem as well
That's unfortunate
we can fix it
as a stopgap and just FYI, you can clone the model and modify it from http://127.0.0.1:6006/settings/models page as follows
hmm. Seems like I am still not getting cost. Invoked the agent a few times just to be sure it wasn't a backdating issue
possibly has to do with the unset status?
great thanks! let me know if I can send over more info
Ok I was able to partially figure it out. The regex needs to match the model string in whole so adding the us. to the beginning gives me pricing on the LLM calls. I still do not have a cumulative cost. a step in the right direction! Regex is tough
