Use the Guardrails API Server#

The NeMo Guardrails library includes the Guardrails API server that exposes guardrails through an HTTP API. This section covers how to run the server and interact with it.

Overview

The Guardrails API server is a tool for running guardrails in a secure, isolated environment.

Overview of the NeMo Guardrails Library API Server
Run the Server

Start the Guardrails API server, configure CORS, and enable auto-reload.

Run the NeMo Guardrails Server
Chat Completions

Send chat requests, use streaming, and manage conversation threads.

Chat with Guardrailed Model
List Configurations

Retrieve available guardrails configurations from the server.

List Guardrail Configurations
Actions Server

Run guardrail actions in a secure, isolated environment.

Use the Actions Server