How to prove a NeMo Guardrails configuration follows your policies with nemoguardrails eval
A team that changes a prompt, a Colang flow or a rail needs evidence that the guarded assistant still follows its policies before the change ships. The nemoguardrails eval command is built for that step. You write the policies the assistant must follow and a dataset of interactions that exercises them. The command runs the configuration against those interactions and reports how responses measure against each policy, with compliance judged by a reviewer or by an LLM judge that you configure. Confirm the exact subcommands, options and output formats against the help text of the version you install, using the NeMo Guardrails documentation as the reference.
Eval answers a different question from the other checks in this group. Unit tests pin specific behavior with fake models and recorded HTTP calls, so they catch deterministic regressions. Per-rail benchmarks measure how individual safety models score on public datasets. Eval measures the whole configuration against the traffic you care about, which is where gaps appear when prompts, flows and rails interact. It does not replace either check. Teams usually need it when they change the policies, switch the model behind a rail or judge, or upgrade the library, because each of these can alter outcomes without breaking a unit test. An LLM judge is also a model, so its verdicts shift with its own version and prompt. Pin the judge and hand-review a sample of its verdicts before you trust a pass rate.
Before a release, agree on thresholds in writing: which policies must pass every time, which may carry a documented tolerance, and which latency and resource ceilings the change must stay within. Then read the three result groups together. Compliance shows whether responses met each policy, resource use shows the model calls and tokens the run consumed, and latency shows how much time the guardrails add. A compliance gain that doubles latency is a trade-off for the product owner to accept, not a silent default. Ask your engineers to confirm which metrics the installed version reports. Store each run's configuration, dataset, judge model and library version with its results so a later audit or regression can reproduce the comparison. Rerun the full set after any change to a prompt, flow, rail, model or library version.
How policies, datasets and the judge produce a release decision
The flow starts with the policy documents and interaction datasets you write for your assistant. Both go into nemoguardrails eval, which runs the configuration against each interaction. Compliance results come from either a manual reviewer or an LLM judge, and the resulting compliance, resource use and latency reports feed the release gate. Check that the judge's verdicts were spot-checked by people before you trust the gate.
Policies and datasets flow through evaluation, judging and reports into a release gate.
Writing policies and interaction datasets that test what matters
Start from the threats and product rules you must enforce, then turn each one into a policy statement that a test can pass or fail. A policy such as "the assistant must not give account-specific tax advice" or "the assistant must refuse requests to reveal the system prompt" is testable. A goal such as "the assistant should be safe" is not. Tie every policy to a named source: a row in your threat model, a product rule owned by a named person, or a regulatory obligation your compliance team has confirmed. Policies without an owner tend to be dropped when a test fails, so record who decides when a policy changes.
Each policy then needs interaction cases with an expected behavior, and the dataset should contain both benign and adversarial cases. Benign cases matter as much as attacks: a dataset with only attacks will reward a configuration that refuses everything. For each policy, write requests a legitimate user would send, requests that should be refused, and borderline requests where the expected outcome is a decision your product owner has signed off. Include multi-turn cases where a rail depends on conversation state. Label every expected outcome explicitly so a later reviewer can see why a case passes.
Before you rely on a dataset format, confirm the file layout, the accepted fields and the options for nemoguardrails eval against the documentation for the exact version you pin, since these inputs have changed across releases. Check the current release notes in the NeMo Guardrails releases page before you upgrade. Keep the dataset in version control next to the configuration, and store the pinned version with each evaluation run so a result can be reproduced months later. Treat datasets as evidence: an auditor or security reviewer will ask which policies were tested and against which version.
Manual review or an LLM judge: how each fits the release process
When a configuration has a handful of policies and a dataset of a few dozen interactions, manual judging is usually the faster and more transparent option. A reviewer reads each model response next to the policy it is meant to satisfy and records a verdict, which keeps the team close to the actual behavior of the guardrails. Manual review also surfaces problems that a judge model may miss, such as a response that is technically compliant but leaks internal wording.
- Reviewer time: Small sets can be read in one sitting, so the cost is mostly the time of the person who knows the policy best.
- Direct observation: Reviewers see the exact reply the application would send, not a summary of it.
- Policy refinement: Disagreements between reviewers often expose vague policy wording, which is cheaper to fix before scale.
- Simple records: A spreadsheet with the interaction, verdict, reviewer and date is often enough for an internal release.
- Limit: Manual review does not scale, and fatigue lowers consistency once a set grows.
Before relying on manual verdicts, confirm with your own team how two reviewers handle borderline cases and write down the rule they agree on.
As interaction datasets grow, an LLM judge scores every response against the policy text and produces a verdict you can aggregate across runs. The judge model is itself a dependency, so its output is only useful after you have measured how closely it agrees with people. Treat the judge as a measurement instrument that needs its own validation, not as an authority that replaces review.
- Throughput: A judge can score large sets on each configuration change, which makes regression comparisons practical.
- Calibration sample: Have humans label a representative subset, then compare agreement with the judge and review the disagreements.
- Judge choice: Confirm which judge model your installed version supports and whether it runs in your environment or calls an external service.
- Prompt control: The judge prompt is part of the method, so edits to it require the same review as edits to policies.
- Ongoing cost: Model calls for judging recur on every run, so ask how many runs a release process needs.
Recalibrate the judge whenever the judge model, its prompt or the policy set changes.
In regulated settings, the release decision needs evidence that a named person accepted the results, and the evidence must show how the results were produced. Manual review gives a clear chain of accountability, while an LLM judge requires documentation of the model, prompt and calibration method. Many organizations use both: the judge scores the full set and humans review a sample, including every failure and every borderline verdict.
- Accountable approver: Record who reviewed each result and who approved the release, using your existing change process.
- Judge provenance: For every result, store the judge model name and version, the judge prompt and the policy file hash.
- Calibration evidence: Keep the human-labeled sample and the agreement figures used to justify trusting the judge.
- Sampling plan: Define in advance which failures and which share of passing results are reviewed by people.
- Independent check: Ask whether your internal audit or compliance function expects a second reviewer on the calibration set.
Ask your compliance lead which evidence they will need to see before the first release, because the format is usually easier to set up at the start.
Calibration measures whether the judge's verdicts match human verdicts on the same interactions. Without it, a judge score is a number with unknown meaning. The process is to label a sample by hand, run the judge on the same sample, compare the verdicts, and study the cases where they differ. Disagreements usually reveal either an ambiguous policy, a weak judge prompt or a judge model that cannot reliably apply the rule.
- Representative sample: Include easy passes, clear violations and borderline cases, not only the obvious ones.
- Blind labeling: Reviewers should label before they see the judge verdict to avoid anchoring.
- Agreement measure: Choose a simple agreement metric and state the threshold your team accepts before the test runs.
- Error direction: Track whether the judge is too strict or too lenient, because the release risk depends on the direction.
- Rework loop: Fix the policy or judge prompt, then repeat the calibration on a fresh sample.
Re-run calibration after any judge model change, since a new model can shift verdicts even when the policy text is unchanged.
Every compliance result should be traceable to the inputs that produced it. A verdict without its judge model, judge prompt and policy version cannot be reproduced, and a later upgrade may make old results impossible to compare. Recording this metadata costs little when it is built into the run, and it is hard to reconstruct afterward.
- Run metadata: Store the NeMo Guardrails version, the configuration folder version, the judge model identifier and the judge prompt text with each run.
- Dataset identity: Keep a fixed copy or checksum of the interaction dataset used for each release.
- Result storage: Save raw verdicts, not only summary percentages, so reviewers can inspect individual cases later.
- Access control: Limit who can change stored results, and log changes to them.
- Retention: Confirm how long your organization must keep release evidence and where it will be stored.
Before the first release, run one dummy evaluation and check that you can rebuild its result from the stored metadata alone.
Which evaluation options fit which release decision
This table compares evaluation configuration choices for nemoguardrails eval, from policy scope and dataset size to judge mode, reporting and CI versus manual runs. Read each row against the release decision in front of you, then confirm the exact options in the documentation for the version you pin, since option names and behavior can change between releases.
| Choice | Typical fit | Trade-off in cost, repeatability and reviewer effort |
|---|---|---|
| Narrow policy scope (a few named policies) | Checking one changed rail, such as a new topic restriction, before merge | Low run cost and quick review, but misses regressions in unrelated policies |
| Full policy suite | Pre-release sign-off for a customer-facing assistant | Longer runs and a larger report to read, but gives the broadest evidence for the release record |
| Small interaction dataset (illustrative: a few dozen dialogues) | Early iteration while prompts and Colang flows are still changing | Fast and cheap to repeat, but results carry wide uncertainty and can hide edge cases |
| Large curated interaction dataset | Release candidates and comparisons between configuration versions | Slower and costlier to run, with more reviewer time, but results are easier to defend to risk owners |
| Manual compliance judgment by reviewers | Small datasets, new policy wording, or disputed LLM judge results | Highest reviewer effort and lowest repeatability across reviewers, but no judge model dependency |
| LLM judge mode | Large datasets where manual review is impractical | Scales with dataset size and model usage cost, but judge drift between model versions can change results, so pin and record the judge model |
| Interactive, human-readable output | Reviewing failures with product owners and security reviewers | Easy to read, but hard to diff between runs and not suited to gating a pipeline |
| Machine-readable output stored with the release | Evidence retained for audits and comparisons across releases | Needs a storage and naming convention and a reviewer habit, but supports repeat comparisons |
| Manual run before release | Exploratory work and one-off investigations | Flexible, but depends on someone remembering to run it and on the same environment each time |
| Scheduled or CI run on every change | Blocking regressions in prompts, flows and library upgrades | Consistent and repeatable, with pipeline compute and model access costs that recur on every run |
Setting up nemoguardrails eval step by step
This sequence takes a NeMo Guardrails configuration from an unpinned environment to a release decision backed by recorded evaluation results. Each step ends with a check you can repeat, so the evidence matches the version that ships.
Pin the Python and nemoguardrails versions
Create an isolated environment on Python 3.11, 3.12 or 3.13, the versions NeMo Guardrails 0.25.0 supports, and install a specific nemoguardrails release such as 0.25.0, published to PyPI on 19 November 2026. Record both versions in your repository and in the evaluation report template. Check: confirm the installed version matches the pin before you go further, so every later result can be traced to these exact versions.
Structure the configuration folder
Lay out the guardrails folder with a config.yml file, the Colang files that define flows and rails, and any optional Python actions. Confirm which Colang version the folder uses, since Colang 1.0 is the default and Colang 2.x requires its own syntax. Check: load the configuration with the Python API or the guardrails server and confirm it parses without errors. The NeMo Guardrails documentation explains each file's role.
Write policies as testable statements
Write each policy as a plain statement with an expected outcome, such as blocking a request category, allowing a topic, or returning a fixed response. Map every policy to the rail or flow that enforces it, and name an owner who can approve changes. Confirm the file format the evaluation tooling expects in the documentation for your installed release. Check: each policy maps to at least one flow in the configuration and has an owner, with no orphaned statements.
Build the interaction dataset
Assemble interaction cases covering benign requests, borderline requests, adversarial prompts, and multi-turn conversations. Give each case an expected verdict tied to a policy. Include benign traffic so over-blocking is measured alongside protection. Illustrative example: a benign billing question should be allowed, while a request for another customer's account data should be refused. Check: have the policy owner review a sample of cases and confirm that every policy has cases in each category.
Choose manual or LLM judging
Decide whether human reviewers, an LLM judge, or both will decide whether each response complies with policy. An LLM judge adds model cost and its own error rate, so record the judge model and version, and set its prompt in version control. Calibrate it by comparing its verdicts with human labels on a sample of cases before trusting it for the full run. Check: the agreement between judge and human labels on that sample is written down, along with who accepted it.
Run the evaluation and save outputs
Run nemoguardrails eval against the pinned configuration, the policies and the dataset, using the judging method chosen in the previous step. Save the compliance, resource use and latency outputs as artifacts alongside the Python version, the library version, the configuration commit and the judge settings. Check: confirm the run covered every dataset case, produced no unexplained errors, and that the saved artifacts reference the same commit you pinned.
Review compliance, resource and latency results
Read compliance results by policy rather than only as an overall score, and review each failure against the expected verdict. Compare resource use and latency with thresholds your team set before the run, and note which rail or model call accounts for the cost. Check: review a sample of judged outputs, especially passes and failures on adversarial cases, and record each disagreement with a decision on whether the policy, the judge or the configuration needs to change.
Gate the release on recorded results
Define pass criteria for each policy and for latency before the run, then block the release when a required policy fails. Rerun the evaluation after every change to prompts, flows, actions or library versions, and store each report with the release record. Check: rerun the evaluation on the release candidate using the same pinned versions and confirm the results match the approved report, or document why they differ.
Reading compliance, resource use and latency results before a release
Read the compliance results policy by policy before you look at any total. A pass rate that looks healthy overall can hide a single policy that now fails on the interactions that matter most to your organization, so list each policy in the evaluation output with its failed interactions and the Colang flow or rail that should have handled them. For each failure, decide whether the gap is in the policy wording, the dataset, the judge or the configuration. Keep the failing interaction IDs in the release record so a reviewer can reproduce each one with nemoguardrails eval against the same configuration.
Resource use and latency need the same discipline. Compare token consumption and response times for the same interaction set on the baseline and the candidate, because a new rail or an extra judge call adds model requests even when every compliance check passes. Confirm which model and endpoint generated each figure, since a change in model or a slower endpoint will move latency without any change to your guardrails. Treat a latency increase as a finding to explain, not as noise.
Separate a configuration regression from variance before you act on a drop. Run the evaluation more than once on the same version and measure how far the results move, then rerun the baseline and the candidate under the same judge model and settings. If an LLM judge is used, pin its model and record its version, since a judge change can shift verdicts without any change to your policies. Only a difference that appears in both the candidate's reruns and the unchanged baseline should be attributed to the configuration. Record the NeMo Guardrails version under test alongside every result, for example by checking the installed package against the release list on GitHub, so the next release can be compared against a known baseline from the previous one.
Security and operational risks in evaluation runs
An evaluation run touches user data, judge model endpoints and reports that summarize how the guardrails behave. The cards below cover the risks that appear once nemoguardrails eval moves from a laptop into a shared pipeline, and the checks to settle before the first run.
Sensitive data in evaluation datasets
Interaction datasets are often built from real support tickets, chat logs or production prompts, which can contain personal data, account details or confidential business text. Before a dataset enters an eval run, decide which fields are removed or replaced with synthetic values, and who may open the file. Ask whether the team has a written rule for what counts as sensitive in a test set, and whether benign examples were checked for leaked identifiers as carefully as attack examples.
Storage of judge prompts and outputs
When an LLM judge scores compliance, its prompts, the application responses it reviewed and its verdicts are written to disk or to a results folder. Those files can repeat sensitive content from the dataset, so they need the same retention and access rules as the dataset itself. Confirm where eval output is written, how long it is kept, and whether it is copied into CI logs or artifact stores by default.
Credentials for judge model endpoints
The judge model is a second model endpoint, and it needs an API key or service credential that the evaluation job can read. Keep that key out of config.yml and out of committed scripts, and give the eval job its own key with a spending limit and the narrowest model access it needs. Rotate the key on the same schedule as other service credentials and confirm that a leaked key cannot be used to reach production models.
Reproducibility across library upgrades
A compliance score is only comparable across releases if the library, the Colang version, the policy text and the judge model stay fixed. NeMo Guardrails 0.25.0 is the current release and it deprecates the LLMRails class in favor of Guardrails, so an upgrade can change how a configuration loads and how results are reported. Record the library version, judge model and dataset hash with every run, and rerun the previous baseline before accepting a new release.
Access control on evaluation reports
Reports summarize which policies failed and which example prompts triggered them, so a report can reveal weaknesses in controls to anyone who reads it. Limit report access to the team that owns the configuration and the reviewers who sign off on releases, and store reports in the same system that holds other security test evidence. Decide in advance whether reports may be shared with product owners in summarized form only.
Evaluation output as release evidence
Eval results often become the record that a configuration was reviewed before release, so a result that cannot be traced is a weak control. Keep the policy version, dataset version, judge settings and a reviewer name with each report, and make sure a rerun can be tied to the same inputs. Ask who approves a failing result, how an exception is recorded, and where the signed report is kept for later review.
Questions teams ask before running nemoguardrails eval
What drives the effort of writing policies and interaction datasets?
The effort follows the number of policies and how precisely each one can be stated. A policy that says the assistant must not give investment advice takes a short time to write, but proving it with a dataset needs benign and adversarial examples, edge cases near the boundary, and agreed labels for what counts as compliant. Each additional policy adds examples to write, review and keep current as the product changes. Teams usually underestimate the labeling work. Ask any partner to show how they will define pass and fail for each policy before dataset work starts, because that definition sets most of the effort.
Can an internal team run nemoguardrails eval without outside help?
Yes, if the team already runs Python tooling and understands its own assistant's behavior. The nemoguardrails package is open source under Apache 2.0, and the library requires Python 3.11, 3.12 or 3.13, so the tooling itself has no license fee. The harder parts are domain knowledge for writing policies, a reviewer who can judge outputs consistently, and time to keep the datasets current. Teams with a clear owner for policy text and a repeatable release gate usually manage the work in house. Teams without a security or compliance reviewer often find that the policy and labeling decisions are where outside help is most useful.
What does the work need from our team?
Plan for three inputs: model access, sample data and reviewers. Model access means an endpoint for the model the assistant uses and, if you choose an LLM judge, a second model to grade outputs, both reachable from the network where evaluation runs. Sample data means realistic user messages and the documents or tools the assistant can reach, with personal data removed or replaced. Reviewers are people who understand the policy and can label outputs. Ask who signs off on policy wording, who resolves disputed labels, and where results are stored, since those answers affect how the evaluation can be cited in a release review.
How long does evaluation take, and what changes the duration?
Duration depends mainly on the number of policies, the size of each interaction dataset, how many model runs each case needs, and how many review cycles the team plans. Evaluation time also grows when an LLM judge is used on every case, because each judgment is another model call that adds latency and cost. The first run is slower because datasets and rubrics are still being tuned. Later runs are faster if the datasets are versioned and rerun on every configuration change. Publicly supplied timing for nemoguardrails eval is not available here, so ask any partner for a timeline tied to your policy count and dataset size in the written scope.
Which results should we check before a release?
Check compliance results per policy, resource use and latency together, not a single pass rate. A compliance figure hides which policy failed and whether the failures are false positives on benign traffic. Resource use shows how many model calls each case triggered, which matters for cost, and latency shows whether the guardrail path is acceptable for users. Record the configuration version, dataset version and judge model with each run so a later change can be compared with the same baseline. Set the release criteria in writing before the run, so the team does not adjust thresholds after seeing results.
Is an outside partner worth it for this evaluation?
A partner is worth considering when the policies carry regulatory or customer risk, when the team lacks reviewers who can judge outputs, or when the evaluation must be repeatable for audit evidence. DeployOpen plans, implements and tests self-hosted open-source platforms in the client's own infrastructure and runs security testing of AI systems and agents, and it prepares systems and evidence for compliance assessments. It does not issue audit reports or certifications. Most engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts, and DeployOpen does not publish a price list, so ask for a quote based on that scope.
Does the NeMo Guardrails package need a paid license for evaluation?
The NeMo Guardrails library is licensed under Apache 2.0, and the current release is 0.25.0, published on 19 November 2026 to PyPI. Using nemoguardrails eval with the open-source library does not require a separate license from NVIDIA. Your costs come from the infrastructure that runs the models, the reviewers who label outputs, and any LLM judge or hosted model you call. NVIDIA has sunset the NeMo Guardrails microservice as of October 1, 2026, so confirm which deployment path your evaluation targets before you build pipelines around it.
How DeployOpen scopes and delivers NeMo Guardrails evaluation work
DeployOpen treats evaluation of a NeMo Guardrails configuration as a written, fixed-scope piece of work: the policies, interaction datasets, judging method and release thresholds are agreed before anyone runs a command. The result is a repeatable evaluation your team can rerun on every configuration change, in infrastructure you control.
How we scope
- We agree in writing which policies, rails and interaction datasets the nemoguardrails eval run will cover.
- We confirm the judging method upfront, manual review, an LLM judge, or both, and which model endpoints the judge may use.
- We record the release thresholds for compliance, resource use and latency so pass or fail decisions are settled before results arrive.
How we build
- We write policy files and interaction datasets against your configuration, then check them with your domain and policy owners.
- We run evaluations on the NeMo Guardrails version you intend to ship, pinned in the environment and recorded with each result.
- We document how each judgment was reached, so reviewers can trace a compliance score back to the exact interaction and rule.
How we hand over
- You receive the policy and dataset files, run scripts and configuration needed to repeat the evaluation without us.
- You receive a written report of compliance, resource use and latency results, with the exceptions and open risks listed.
- We walk your engineering and compliance teams through the results and the steps to rerun the evaluation before each release.
How we support
- Ongoing support, upgrades and continuous testing are available as a retainer, including re-running evaluations after NeMo Guardrails upgrades.
- Before a retainer starts, confirm with us which NeMo Guardrails release line and Python version your evaluation environment will use.
- Ask for a quote that lists each deliverable, the environments we access, and who on your side reviews the judgments.

