target block changes between them — the rest of the payload is identical.
Prerequisites
- Python basics
- Accounts with the model providers you want to test
- An Enkrypt AI API key from app.enkryptai.com
Setup
Shell
Shell
Shell
The script
This template works for every provider. Swap thetarget block from the sections below.
Provider configurations
OpenAI
Anthropic
Azure OpenAI
For Azure the
model_name is your deployment name, not the underlying model name, and
the API version belongs in the endpoint query string.AWS Bedrock
Google Gemini
Together
Replicate
HuggingFace Inference Endpoint
Any OpenAI-compatible endpoint
The general escape hatch — vLLM, Ollama, LM Studio, OpenRouter, Groq, Fireworks, self-hosted gateways and most other services expose an OpenAI-shaped API.provider is a routing hint. When in doubt, use openai_compatible — if the endpoint
speaks the OpenAI chat-completions shape, it will work. Other recognised values include
mistral, cohere, deepseek, groq, fireworks, openrouter, xai, ai21,
ollama, litellm and portkey.Saved models
Rather than repeating a target block, save the model once through the Models API and reference it:Shell
target at all — the saved model supplies it. See
Run Red Team with a Saved Model
for the exact headers.
Targets inside a private network
If the model is not reachable from the public internet, route it through the Relay bridge withconnect_via_relay on the target and a metadata.relay block naming the
bridge. See
Red Teaming Through the Relay Bridge for the
end-to-end walkthrough, and
Configuration Reference
for the field reference.
Comparing providers
Because onlytarget changes, you can run the same scope against several models and
compare summary.overall_asr:
Python
For a like-for-like comparison, use the same
generation_config.dataset_name across runs
so every model sees an identical prompt set. Generate it once with
threat modeling.Related
- Quickstart — the full run cycle
- Configuration Reference — every
targetfield - Examples — complete payloads
- Model Health — verify a target before running

