Prerequisites
Before you begin, ensure you have:- Cerebras API Key - Get an API key at cloud.cerebras.ai
- Operant AI Gatekeeper and Gateway - Sign up at operant.ai and ensure both the Gatekeeper and Gateway container are installed and running in your environment
Configure Operant AI Gateway
Configure environment variables
Create a Your gateway base URL will look like one of these:
.env file in your project with your credentials and gateway settings:https://operant-gateway.mydomain.com/ai-gateway/v1http://operant-gateway.operant-namespace.svc:9000/ai-gateway/v1(if using the Kubernetes service directly)
Install required dependencies
Install the OpenAI Python SDK and dotenv:Cerebras exposes an OpenAI-compatible API, so the standard OpenAI client works without modification.
Initialize the client
Configure the OpenAI client to route requests through the Operant Gateway. Two headers are required on every request:
x-gateway-source— identifies your applicationx-gateway-target— tells the gateway where to forward traffic
Make your first request
Make a chat completion request. The call is identical to a standard Cerebras request — the gateway handles routing and security enforcement transparently.
Supported Models
The Operant Gateway supportsgpt-oss-120b and zai-glm-4.7.
What You Get from Operant
Once traffic flows through the Operant Gateway, the following capabilities are available:Prompt Injection Blocking
Prompt Injection Blocking
Gatekeeper detects and blocks prompt injection attempts including jailbreaks and system override tricks before they reach the model.
PII and Secrets Redaction
PII and Secrets Redaction
Sensitive data — including PII, PCI, PHI, and API keys — is automatically detected and redacted across over 100 data types before requests are forwarded to Cerebras.
Sensitive Data Extraction Prevention
Sensitive Data Extraction Prevention
Gatekeeper monitors responses and stops attempts to extract sensitive data through the model.
Rate Limiting
Rate Limiting
Configure per-team, per-agent, or per-address rate limits to control abuse and manage costs. Exceeded limits return a 429 status code.
LLM Poisoning Prevention
LLM Poisoning Prevention
Protects against data poisoning attacks targeting your AI application’s training or inference pipeline.
Security Graph
Security Graph
Operant provides a visual security graph that surfaces all AI traffic once inference calls are flowing through the gateway. It highlights PII detections, prompt injections, and secrets found in prompts and responses.
Guardrails
Guardrails
Operant provides a configurable set of guardrails covering governance policies, prompt injection blocking, and sensitive data inline blocking and redaction. These can be applied per application through the Operant dashboard.

