Lesson 2 of 5 Generative AI and Machine Learning Architectures

Governing Generative AI Across Many Accounts

This lesson compares decentralised and centralised patterns for using Amazon Bedrock in a multi-account organisation and explains the controls that apply to both.

Learning outcomes

After completing this lesson, you will be able to:

  • Compare decentralised use with central guardrails and a central generative AI gateway.
  • Identify the organisation-level controls for models, guardrails, logging and residency.
  • Choose a pattern from requirements for quotas, chargeback and policy enforcement.

Decentralised use with central guardrails

In the decentralised pattern, each workload account calls Bedrock directly with its own IAM roles. Governance is applied from the organisation: SCPs deny invocation of models and inference profiles outside an approved list; Bedrock policies in AWS Organizations apply a guardrail to every model call in targeted accounts, or SCPs require one with the bedrock:GuardrailIdentifier condition key; a StackSets or Control Tower baseline turns on model invocation logging to a central log archive; and quotas are requested per account. This pattern is simple and keeps each team's costs in its own account, but every account needs the same baseline.

A central generative AI gateway

In the centralised pattern, a shared AI platform account exposes a gateway (for example API Gateway with Lambda, or a proxy on ECS behind an ALB) that is the only path to Bedrock. Workload accounts call the gateway with IAM or tokens, and the gateway authenticates the caller, applies per-team quotas and rate limits, attaches the standard guardrail, logs prompts and responses, selects models and inference profiles, and records token usage per team (for example through tagged application inference profiles). Shared resources such as knowledge bases and guardrails live in the platform account. The gateway adds a component to operate and scale, but gives one place for policy and visibility.

The following comparison summarises the trade-offs.

Decentralised
Where calls goEach account calls Bedrock
Policy enforcementSCPs, Organizations Bedrock policies, baselines
Quotas and costPer account
Operational effortBaseline in every account
Choose when A few teams with standard controls and separate budgets.
Central gateway
Where calls goAccounts call a shared gateway
Policy enforcementIn the gateway, plus SCPs as a backstop
Quotas and costPer team, managed centrally
Operational effortGateway to build and run
Choose when Many teams needing shared quotas, logging, model routing and chargeback.

The following diagram shows the centralised gateway pattern.

A central generative AI gateway. Workload accounts call a gateway in a shared AI platform account, which is the only path to Amazon Bedrock. The gateway authenticates the calling team, enforces its token quota, applies the standard guardrail and logs every prompt and response, which also gives per-team chargeback.
The gateway is the one place where quotas, the guardrail and logging are applied, at the cost of a shared component that every team depends on.
Sort into groups

Decentralised or central gateway?

Exam skills 1.2.1 · 2.5.2

Decide which multi-account pattern each statement describes.

Log in to try this activity Interactive activities are free with an account.

Controls that apply to both

  • Model access: least-privilege IAM on model and profile ARNs, and SCPs denying unapproved models; the first use of some third-party models also needs AWS Marketplace subscription permissions.
  • Network: interface VPC endpoints with endpoint policies that restrict principals and models.
  • Data residency: in-Region models or geographic inference profiles, with global profiles denied where data must stay in a geography.
  • Audit: CloudTrail for API calls and model invocation logging for content, delivered to the log archive account.
Select all that apply

Controls for every pattern

Exam skills 1.2.1 · 2.4.4

Identify controls that apply to generative AI use in any account pattern.

Log in to try this activity Interactive activities are free with an account.
Worked example

AI for 40 product teams

A bank has 40 product teams, wants per-team token quotas and chargeback, one standard guardrail and one place to see every prompt.

The architect builds a gateway in an AI platform account: an API Gateway private API with a Lambda integration, called by workload accounts through interface endpoints. Each team has an application inference profile tagged with its cost centre; the gateway maps the caller's role to the team's profile, enforces a usage plan, applies the guardrail and writes invocation logs to the log archive.

As a backstop, an SCP denies bedrock:InvokeModel and the Converse actions in every workload account except for the gateway's role, so a team cannot bypass the gateway by calling Bedrock directly.

Check yourself

In the central gateway pattern, what stops a team from bypassing the gateway and calling Bedrock directly?

Show answer

An SCP in the workload accounts that denies Bedrock invoke actions for every principal except the gateway's role. The gateway enforces policy, and the SCP makes it the only path.

Exam Tips

Remember for the exam

  • Only approved models in every account: SCP on Bedrock invoke actions with approved model ARNs.
  • Per-team quotas, logging and chargeback for many teams: central generative AI gateway with tagged application inference profiles.
  • Guardrail applied to every call in some OUs: Organizations Bedrock policy.
  • Stop teams bypassing the gateway: SCP that allows invocation only for the gateway role.