Guardrails and audit6 of 8

OpenAI Guardrails

OpenAI Guardrails is an open-source Python library that wraps the OpenAI client and runs configurable checks on model inputs and outputs.

guardrails.openai.com ↗ Documentation ↗ Source code ↗

Compare side by side
Lowest paid plan
None for the library
Free tier
Free (open source)
License
Open source (MIT)
Self-hosting
Only option

No pricing page this site can read daily.

Facts checked , from 4 sources

What OpenAI Guardrails does

OpenAI Guardrails replaces the OpenAI client class in an application with a wrapped one. Every Chat Completions or Responses call then passes through a pipeline of checks at three stages, which the docs call pre-flight, input and output, and a failed check raises an exception the application handles. The pipeline is a JSON file, written by hand or exported from a web-based wizard.

Twelve checks are listed: keyword filter, competitor mentions, moderation through OpenAI's moderation API, URL filter, secret keys, personal data, hallucination detection against reference material in vector stores, jailbreak, prompt injection in tool calls and tool outputs, workplace-inappropriate text, off-topic prompts and a custom prompt check. Several of them work by calling a language model that you name in the configuration. The library also provides an agent class for the OpenAI Agents SDK, a client for Azure OpenAI, and an evaluation tool that measures a configuration against a labeled dataset.

OpenAI Guardrails: owner, license, hosting and price

Each value was read from the vendor's own page on the date shown. How listings are checked

Fact Value Source and date checked
Owner OpenAI. Source ↗
License MIT. Source ↗
Self-hosting Yes, it only runs inside your own application, installed as a Python package. Python 3.11 or later. Source ↗
Hosted regions No hosted service. Checks that use a model call the OpenAI API, Azure OpenAI or another OpenAI-compatible endpoint that you configure. Source ↗
Free tier The library is free to use under the MIT license. The Moderation check needs an OpenAI API key, at no cost according to the docs. Source ↗
Pricing model No charge for the library. Checks that call a language model consume tokens, billed by whichever model provider you configure. Source ↗
Lowest paid plan None for the library. The docs state no price for the model calls its checks make. Source ↗

OpenAI Guardrails pricing history

OpenAI Guardrails has no public pricing page for this site to watch.

Where OpenAI Guardrails fits

Teams whose code already uses the OpenAI Python client or the OpenAI Agents SDK: the change is one class name and a configuration file. The docs say it works with any OpenAI-compatible API, with a local Ollama model as the example, and the bundled evaluation tool measures a configuration against your own labeled data.

Limits of OpenAI Guardrails

The readme labels it a preview. It needs Python 3.11 or later, and the personal data check needs a spaCy model installed at build time. Checks that call a language model, such as jailbreak and the custom prompt check, consume tokens on every request. Pull requests are accepted from repository collaborators only.

Alternatives to OpenAI Guardrails

  • Amazon Bedrock Guardrails
    Amazon Bedrock Guardrails is a managed AWS service that filters prompts and model responses against content, topic and sensitive-data policies.
    $0.10 per 1k text units Compare
  • Arthur Evals Engine
    Arthur Evals Engine is an open-source service you host that applies guardrail rules to LLM prompts and responses and collects traces for evaluation.
    $60 a month Compare
  • Google Model Armor
    Model Armor is a Google Cloud service that screens LLM prompts and responses for prompt injection, harmful content, sensitive data and malicious URLs.
    $0.10 per 1M tokens Compare
  • Lakera Guard
    Lakera Guard is an API that screens prompts, tool calls and model outputs for prompt attacks, data leakage and unwanted content.
    Quote only Compare
  • NVIDIA NeMo Guardrails
    NVIDIA NeMo Guardrails is an open-source Python library for adding programmable input, dialog, retrieval and output checks to LLM applications.
    None for the library Compare
  • Presidio
    Presidio is an open-source Python framework that detects and anonymizes personal data in text, images and structured data.
    No paid plan Compare
  • SignalVault Built by this site's editor
    SignalVault is a hosted proxy that logs requests to OpenAI and Anthropic models and blocks or redacts sensitive data in them.
    $49 a month Compare
Compare OpenAI Guardrails with them