AI Cloud Architect

Building a self-service LLM gateway with Amazon Bedrock and LiteLLM

AWSHow-to by Sitaraman Vijay Krishna, Eric Christensen and Saurav BhattacharyaAWS Artificial Intelligence Blog

Build a self-service LLM gateway with LiteLLM on AWS Fargate that puts Amazon Bedrock foundation models behind an OpenAI-compatible API. Developers get instant access through a single API key, while platform teams gain per-user cost controls, quota isolation, and observability.

Read the original (opens the source's page in a new tab)

AI: Summary

What it is

Shows how to put Amazon Bedrock models behind a LiteLLM proxy on AWS Fargate with an OpenAI-compatible API, per-key spend limits, and CloudWatch token metrics.

Who it is for

Platform teams running coding assistants for developers on Amazon Bedrock who need per-user cost limits and quota alarms.

Key points

  • Spend limits need per-model costs set in model_info, otherwise inference-profile ARNs record $0 and budgets never enforce.
  • Global cross-Region inference needs IAM permissions on foundation-model ARNs as well as the inference profile.
  • Post notes LiteLLM self-service key issuance requires the Enterprise version.

The same at other vendors

Timeline

  1. What it explainsStreamline AI operations with the Multi-Provider Generative AI Gateway reference architecture · AWS · Blog post
  2. This postBuilding a self-service LLM gateway with Amazon Bedrock and LiteLLM

Go deeper