← Back
AWS ML Blog

Part 2: Amazon Bedrock cost attribution with Amazon Athena and CUDOS

13 min read
#bedrock#amazon#enterprise#deployment
Level:Intermediate
For:AI Engineers
TL;DR

Amazon Bedrock's granular cost attribution feature allows for per-user and per-application visibility, and can be visualized and analyzed using Amazon Athena queries and CUDOS dashboards. The process involves setting up a Cost and Usage Report (CUR) 2.0 data export with IAM principal data, which can then be queried using Amazon Athena for analysis. CUDOS dashboards provide pre-built visuals tailored to an organization's specific structure, offering a more streamlined approach to cost and usage analysis. The practical implication for engineers building AI systems is the ability to track and manage costs at a granular level, enabling more efficient resource allocation and cost optimization. With this approach, engineers can typically track usage at the granularity they want for any Bedrock-powered service or application.

⚡ Key Takeaways

  • The line_item_iam_principal column in CUR 2.0 provides per-user and per-application visibility.
  • Amazon Athena can be used to query CUR data for analysis, with options for hourly time granularity and file versioning.
  • CUDOS dashboards offer pre-built visuals for cost and usage analysis, tailored to an organization's specific structure.
  • Enabling IAM principal data in CUR 2.0 increases file sizes, so planning for Amazon S3 storage is necessary.
  • The "Include caller identity (IAM principal) allocation data" checkbox is critical for populating the line_item_iam_principal column.
💡 Why It Matters

The ability to track and manage costs at a granular level is crucial for engineers building AI systems, as it enables more efficient resource allocation and cost optimization. With Amazon Bedrock's cost attribution feature and Amazon Athena's querying capabilities, engineers can gain valuable insights into their usage patterns and make data-driven decisions to optimize their systems.

✅ Practical Steps

  1. Set up a Cost and Usage Report (CUR) 2.0 data export with IAM principal data.
  2. Connect CUR 2.0 to Amazon Athena for querying and analysis.
  3. Use Amazon Athena to query CUR data, selecting options such as hourly time granularity and file versioning.
  4. Utilize CUDOS dashboards for pre-built visuals and streamlined cost and usage analysis.

Want the full story? Read the original article.

Read on AWS ML Blog

More like this

Building an AI Text Detector From Scratch

Ahead of AI#llm

Custom reward functions for multi-turn reinforcement learning with Amazon Nova Forge

AWS ML Blog#amazon

Record, train, and deploy from one place with Strands Agents, LeRobot, and Hugging Face Storage Buckets

Hugging Face Blog#agents

A decade of mathematical certainty: Reflections on the Automated Reasoning Group

Amazon Science#inference

EXPLORE AI NEWS

Daily hand-picked stories on LLMs, RAG, agents and production AI — curated for engineers who ship.

BROWSE NEWS

GET THE WEEKLY DIGEST

Join engineers getting the Monday signal-over-noise AI breakdown. No spam, unsubscribe anytime.

LEARN AI ENGINEERING

Curated courses, research papers, repos and tutorials built for engineers leveling up in AI.

START LEARNING