Prompt Pin

Keep an AI agent on the prompt version you approved. Prompt Pin denies a model call when a Traccia prompt was loaded from a different label or version.

Real-Time(Preventive)Checked before the call runs, so it can stop it

You pin the Traccia prompt refund-policy to the label production, or to one version. If an agent loads that prompt from any other label, such as staging, the model call is denied.

Runs On
The SDK only
You Set
The prompt name, and the label or version it must use.
Your Agent Sends
A prompt loaded and compiled through Traccia

What Happens

With refund-policy pinned to production and Block on:

What the call loadedResult
refund-policy, label productionThe model call runs.
refund-policy, label stagingThe model call is denied.
A different prompt nameThis rule does not apply. The model call runs.
No Traccia prompt on the callThe rule is skipped and the call runs. The match is recorded as a warning.

Set It Up

  1. In the app, open Policies and click Create Policy.
  2. Choose Prompt Pin.
  3. Enter the Prompt Name. Under Pin By, choose Label or Version Id, then enter the value, such as production.
  4. Set the mode to Block, then click Activate Policy.

What Your Agent Sends

Load and compile the prompt through Traccia inside govern, then make the model call. A prompt string you wrote in code has no label, so Prompt Pin skips it. Prompt loading is covered on Prompts. See the code.

Good To Know

  • A fallback prompt is not denied just because it is a fallback.
  • Prompt Pin does not replace the prompt library, and it does not require every agent to load prompts from Traccia.
  • This policy does not apply on the Gateway.

Next Steps

© 2026 Traccia.