ON-PREM CHOREO CLOUD BOTH

What you will learn

  • Say what an LLM provider and an LLM proxy are, and which one holds the vendor key
  • Explain why an agent holds a proxy key and does not need the vendor key
  • Define a guardrail and say where it is enforced
  • Tell where the list of available guardrails comes from

Before you start

On this page

A language model is a service run by a vendor, and the vendor charges for every call. If every agent in your company holds the vendor’s key, one leak means a stolen key and a large bill. Agent Manager puts a gateway in the middle and splits the key in two.

Two objects

An is the organisation’s connection to a model vendor. You create it from a . The built-in templates are openai, anthropic, awsbedrock, azure-openai, azureai-foundry, gemini and mistralai. The provider holds the vendor’s address and the vendor key. AMS encrypts the key before it saves it.

An is a project’s entry point. It points at one provider and has a key of its own, the . Agents call the proxy. When you attach a model to an agent, or choose a judge model for a monitor, Agent Manager creates the proxy resources for you.

Component

LLM provider / proxy

Shared or other Other BOTH

An LLM provider is an organization-level connection to a model vendor such as OpenAI or Anthropic. It is created from a provider template and holds the upstream address and the vendor key. An LLM proxy is a project-level entry point that points at a provider and has its own API key. Providers and proxies are deployed to gateways, and agents and evaluation monitors call the proxy, never the vendor directly.

Providers and proxies are saved in AMS’s database. To take effect they are deployed to a gateway, which learns about them over its WebSocket connection to AMS.

Why two keys

  1. The agent holds the proxy key

    The agent shows the proxy key to the . The key works for that proxy only. If it leaks, you cancel it and the vendor account is untouched.

  2. The gateway holds the vendor key

    The key reaches the gateway ahead of time, when the provider is deployed. At call time the gateway adds it to the outgoing request, so the agent does not hold it.

Lesson L4.3.1 follows the whole call in detail. This lesson stays at the level of the objects.

Guardrails

A is a gateway policy that checks or limits the traffic of an LLM provider, an LLM proxy or an MCP proxy. Two ideas matter most.

  • It is enforced at the gateway. Rules about what agents may send live in one place, so they apply without changing any agent code.
  • It is part of the configuration. A guardrail is saved in the provider or proxy configuration as a name, a version and a list of settings. Adding one goes through the ordinary update call, and then the configuration is deployed to the gateways.

The gateway’s build file lists many policies. Some limit the size of what is sent, such as content-length-guardrail and word-count-guardrail. Some look at the content, such as pii-masking-regex and regex-guardrail. Others limit usage, such as the request, token and cost based rate limits.

Component

Guardrails and policies

Shared or other Other BOTH

Guardrails are gateway policies that check or limit the traffic of an LLM provider, an LLM proxy or an MCP proxy, for example content filters or rate limits. A policy is saved in the provider or proxy configuration as a name, a version and a list of paths with settings. Agent Manager finds out which policies exist from the gateways themselves.

Where the menu comes from

Each gateway pushes the manifest of the policies it has installed to AMS when it connects. The console’s policy lists are answered from that push. A policy counts as available only if every gateway in scope has it, so a gateway that is missing a policy takes it off the menu.

Your turn

Open Try it. Scroll the story to follow one request, then open The credentials map and click the row for the LLM proxy API key. Read who holds it and who checks it. Finish with the matcher on providers, proxies and keys.

Recap

  • A provider is the organisation’s vendor connection and holds the vendor key. A proxy is a project’s entry point with a key of its own.
  • The agent holds the proxy key. The gateway adds the vendor key to the outgoing call.
  • A guardrail is a gateway policy, so it applies without changing agent code.
  • The menu of guardrails comes from the policy manifests that the gateways push to AMS.

Try it

Watch the story

What to do: scroll, press J and K, or use the Next scene button. The diagram follows the story.

Loading the story...

  1. The agent has a question. Your agent needs an answer from a language model. It does not call the vendor. It calls the AI gateway that sits in front of the vendors.
  2. The request goes to the gateway. The agent sends its request to the gateway and shows a proxy key. That key only works for one proxy, and the agent does not receive the vendor's key.
  3. The policy engine checks the key. The router hands the request to the policy engine. When the proxy needs a key, the key check comes first, then the guardrails, rate limits and cost tracking you configured.
  4. Inside the checkpoint. In the gateway view you can see the two parts that matter here. The router receives the request, and the policy engine runs the rules.
  5. The gateway adds the real key. The vendor key was handed to the gateway ahead of time, when the provider was deployed. At call time the gateway adds it to the outgoing request and calls the vendor.
  6. Why this shape. Rules about what agents may send live in one place, so they apply without changing agent code. A proxy key can be cancelled without touching the vendor account.
  7. The same trip leaves a trail. The gateway also carries the agent's traces. It forwards a trace only if the agent's trace token checks out, and hands it to the collector.
  8. Read it back in the console. When you open the traces page, the console asks the observer service directly. AMS is not in that path.

The credentials map

What to do: click a credential to see who holds it, who checks it and where it travels.

Loading the simulator...

Match them up

What to do: pick an item on the left, then its partner on the right.

Loading the matching game...

Wrap up

Recap

Tick each one when you could explain it to a colleague.

Finished?

Quick check

Loading the quick check...

Spotted something wrong or unclear in this lesson? Report an inaccuracy (opens GitHub in a new tab)