Migrating from Azure AI Content Safety to NeMo Guardrails

Teams moving Prompt Shields, harm category analysis, groundedness detection and custom categories to self-hosted NeMo Guardrails need a mapping, a threshold plan and a parallel run before cutover. This page covers each step and what drives the effort.

On this page

Moving from Azure AI Content Safety to NeMo Guardrails: what the move involves

If your application calls Azure AI Content Safety for every request and you now need those checks to run in infrastructure you control, plan this as a re-implementation of rails, not a file import. Azure AI Content Safety returns verdicts from a hosted API, while NeMo Guardrails expresses checks as input rails, output rails, dialog rails, retrieval rails and execution rails configured through a config.yml file, optional Python actions and Colang files. Prompt Shields, harm category analysis, groundedness detection and custom categories each need a target rail, a model or check that replaces the hosted behavior, and a threshold set by your team. Effort depends mostly on how many of these features your application uses, how many custom categories you have defined, and how much of your moderation logic currently lives in application code rather than in the service configuration.

The NeMo Guardrails library is licensed under Apache 2.0, so you can run it in your own environment without a license fee for the library itself. The hosted NeMo Guardrails microservice is different: NVIDIA's NGC catalog states that NeMo microservices has been sunset as of October 1, 2026, with no new releases and no continued support for the artifact. Do not design a new deployment around that container. Instead, build on the library, which currently ships as release 0.25.0 and requires Python 3.11, 3.12 or 3.13. Before you commit, confirm with your NVIDIA account team which NeMo Platform components you will need, since NVIDIA's NeMo Guardrails documentation covers the library and not the platform roadmap.

Start by inventorying every Azure AI Content Safety call your application makes, including the categories, severity levels and blocklists configured in the Azure resource, because those settings are the thresholds you must match during the move. Record the current verdicts on a representative sample of traffic, then map each category to a self-hosted model or custom check in NeMo Guardrails and decide which severity cutoffs you will reproduce. Ask your security team to confirm which evidence they need for each threshold, since a threshold that cannot be explained will be difficult to defend in a review. Azure's own behavior and limits should be confirmed in the current Azure documentation and your contract, not assumed from this summary.

Which Azure AI Content Safety features map to NeMo Guardrails rails

This table pairs each Azure AI Content Safety feature your team uses with the closest NeMo Guardrails rail, self-check prompt, detector or custom action, and notes where a custom build or model choice is needed. Confirm current Azure feature names and behavior against Microsoft's documentation before relying on any row, because no one-to-one mapping is assumed. Use it as a starting inventory for the migration, not as a parity claim.

Azure featureNeMo Guardrails equivalentCustom build or model choice
Prompt Shields (user prompt attacks)Input rails with NVIDIA jailbreak and injection detection, plus heuristic checksChoose the detection model and tune thresholds on your own traffic; confirm coverage of indirect injection in documents
Harm category analysis on user inputInput rails using self-check input moderation or the NVIDIA content safety modelSelect a safety model and map its categories to your policy; add custom Colang flows for categories it does not cover
Harm category analysis on model outputOutput rails using self-check output moderation or the content safety modelDecide whether to block, rewrite or replace the response, and define the refusal message in Colang
Groundedness detectionRetrieval rails for RAG chunks, plus fact-checking and hallucination detection railsChoose a grounding model or self-check prompt; expect calibration against your own answer set
Custom categoriesSelf-check prompts, topic safety model, or a custom action that calls your classifierUsually requires custom build: write the policy prompt, labeled test data and the action code
Blocklists (Azure text blocklists)Input or output rails with a custom action that matches your term listPort the term list yourself, including normalization and version control; no direct import is assumed
Severity levels and thresholdsNo native equivalent; expressed as rail outcomes and per-category decision logicRecalibrate thresholds from recorded Azure scores or labeled samples, since scales are not interchangeable
Content moderation for imagesNo direct NeMo Guardrails rail is assumed; confirm multimodal support for your versionLikely needs a separate model or service; confirm before scoping

Why the hosted NeMo microservice path is closed for this move

NVIDIA has sunset the NeMo microservices as of October 1, 2026, so the hosted NeMo Guardrails container is no longer a viable target for this migration. The NGC catalog page for the guardrails container states there will be no new releases and that the artifact is no longer supported. NVIDIA's archived NeMo Microservices documentation says all new development has moved to NeMo Platform and asks existing users to contact their NVIDIA account team to discuss next steps. If your Azure AI Content Safety replacement was going to run as a NeMo microservice, treat that design as withdrawn and do not build new work on the container.

Two open-source paths remain. The first is the nemoguardrails library, currently release 0.25.0 on PyPI under Apache-2.0, which requires Python 3.11, 3.12 or 3.13. You can call it from Python or run it as a guardrails server that loads configurations from a folder and exposes an HTTP API, using the Dockerfile the project provides. The second is NeMo Helix, an Apache-2.0 control plane that runs NeMo Guardrails as an inference gateway middleware plugin, applying guardrail configurations to model endpoints. Helix suits teams that want guardrails enforced centrally across several model endpoints. The library suits teams that want guardrails inside a single application they already run.

Before you pick between them, confirm with NVIDIA which path fits any existing contract, support arrangement or licensing you hold, since the archived notice points those users to their account team. Ask in writing what happens to current entitlements and what support, if any, applies to the library or Helix. Plan on the library or Helix as the target for this migration, and record the decision and the NVIDIA response in your migration plan so the architecture review can reference it.

Documented import, conversion and deployment paths for the move

NeMo Guardrails offers several documented ways to run and integrate a configuration, and each one affects how you structure the move from Azure AI Content Safety. None of them imports Azure settings, so the work that carries over is the design of your rails and thresholds, which you rebuild by hand.

Python API with the Guardrails class

Your application calls NeMo Guardrails directly from Python, which suits teams that already wrap Azure Content Safety calls in their own service code. Version 0.25.0 deprecates the LLMRails class in favor of Guardrails, and the old class is planned for removal no earlier than 0.27.0. Check every import path in your code before you pin a version, and plan to use the Guardrails class for new work.

NeMo Guardrails docs

Guardrails server with a config folder

The server loads a configuration folder at startup and exposes an HTTP API, so Azure-era callers can move to a network call without changing their application language. Each folder holds a config.yml file, optional Python actions and Colang files. Confirm which request and response fields your existing callers depend on, because the HTTP contract differs from the Azure Content Safety API.

Dockerfile for a server image

NeMo Guardrails provides a Dockerfile that builds a server image, which is the packaging step for running the rails in your own cluster or cloud account. The image runs the rails you have written, not your Azure resource settings. Check the Python version the image uses against the 3.11, 3.12 or 3.13 requirement, and confirm how your registry, secrets and model endpoints are wired in.

The convert tool for Colang 1.0 to 2.x

The nemoguardrails convert tool moves Colang 1.0 flows to Colang 2.x, which matters only if you adopt the newer syntax for dialog rails. NVIDIA states that converted configurations still need manual review, so every converted flow must be tested against your recorded cases. Plan review time for each flow, since the tool does not translate any Azure threshold or category logic.

Colang 2 migration guide

LangChain integration by environment variable

If your assistant is built on LangChain, the integration is opt-in and turns on with the NEMOGUARDRAILS_LLM_FRAMEWORK environment variable set to langchain. This lets you place rails around existing chains without rewriting them. Confirm that the framework setting is applied in every environment, including test and staging, so rails do not run in one place and silently skip in another.

How migrated rails sit between the application and the model endpoint

The diagram starts at the user request arriving at the application, which forwards it to the self-hosted NeMo Guardrails server. Input rails run first, then the model call goes to the model endpoint, and output rails check the response before it returns to the user. Inside the trust boundary sit the rails and the safety models they call. The parallel run path copies recorded traffic to both Azure AI Content Safety and the NeMo Guardrails server, and writes both verdicts to a comparison store. Check that every hand-off stays inside your environment and that verdicts are logged in the same shape on both sides.

Live request path with the parallel run that compares verdicts from both systems.

Sequence: inventory, pilot, parallel run, cutover and decommission

The sequence moves Azure AI Content Safety checks to NeMo Guardrails in a controlled order, so each call site is mapped, tested against recorded traffic, switched with a rollback path and only then removed from Azure.

  1. Inventory every Azure call site and setting

    Your platform engineers list every application, gateway and pipeline that calls Prompt Shields, harm category analysis, groundedness detection or custom categories. For each call, record the endpoint, the API version, the categories requested, the severity thresholds, any blocklists, the action taken on a hit, and the logs or dashboards that depend on the result. Include calls made from batch jobs and staging environments, which are easy to miss. The step is done when the inventory is reviewed by the application owners and by the security team, who confirm that no call site is missing and that every threshold has a documented owner.

  2. Map each control to a rail or action

    For each inventory line, decide whether the check becomes an input rail, an output rail, a retrieval rail for RAG chunks, an execution rail for tools, or a custom action backed by a self-hosted model or classifier. Harm categories and jailbreak checks usually map to built-in NeMo Guardrails models, while custom categories often need a Colang flow or a Python action. Record where a control has no direct equivalent and needs a design decision. Your compliance team signs off on the mapping, particularly where a control protected a policy commitment, because the replacement must cover the same risk even when the mechanism differs.

  3. Build and test a pilot on NeMo Guardrails 0.25.0

    In a non-production environment, install the nemoguardrails library at version 0.25.0 on a supported Python version (3.11, 3.12 or 3.13) and build the configuration with config.yml, Colang files and any actions. Use the Guardrails class, since LLMRails is deprecated in this release. Host any self-hosted safety models in the same environment so latency and resource use can be measured. Run unit tests against known prompts and responses for each rail. The step is done when every mapped control has a passing test case, and the results, model versions and configuration files are stored in version control for review.

  4. Run both systems in parallel on recorded traffic

    Replay a sample of recorded production requests and responses through Azure AI Content Safety and the NeMo Guardrails pilot, then compare the verdicts for each control. Classify every disagreement as a missed detection, a false positive, or a threshold difference, and tune the NeMo Guardrails thresholds until disagreements are understood and accepted. Keep Azure as the enforcing system during this step, so users are not affected. Your security and compliance teams review the disagreement log and the accepted residual gaps, and they sign off before any traffic moves. Record the sample size and selection method so the comparison can be reproduced.

  5. Cut over call sites in stages with rollback

    Switch call sites one group at a time, starting with the lowest-risk applications, and route each group through NeMo Guardrails with a feature flag or gateway setting that returns traffic to Azure in one change. Watch block rates, error rates, latency and user reports after each stage, and do not proceed while any of them moves outside the agreed range. Keep Azure configured and reachable during the cutover window so rollback stays available. The step is done when all inventoried call sites run through NeMo Guardrails, and the change records show who approved each stage.

  6. Decommission Azure resources after retention

    After the retention period that your organization sets, disable Azure AI Content Safety calls, revoke the API keys and managed identities that reached the service, and delete the resource. Before deletion, export the logs, evaluation results and configuration records that your auditors or incident responders may need, and confirm where they are stored. Ask your procurement and legal teams to confirm any contractual notice terms and any data retention rules that apply to the Azure resource. The step closes when the security team confirms that no active credentials remain and the decommission record is filed with the migration evidence.

Matching severity thresholds before the parallel run ends

Azure AI Content Safety reports harm categories with severity levels, while NeMo Guardrails returns verdicts from the rails you configure: a self-check prompt, a classifier score from a self-hosted safety model, or a Colang flow outcome. These do not sit on a shared scale, so copying an Azure severity cutoff into a classifier threshold will not reproduce the same decisions. Thresholds must be calibrated against labeled examples from your own traffic before the parallel run ends. Confirm the current severity scale, category names and any output-type options in Microsoft's Azure AI Content Safety documentation, because those details change and your calibration record should cite the version you tested against.

Start by building a baseline from the existing Azure verdicts. Export a representative sample of prompts and responses that Azure has already scored, including the categories, severity values and Prompt Shields results, and have two reviewers label each item as should-block or should-allow against your written policy. Keep items that Azure flagged near its cutoff, since those define where the boundary actually sits. Then run the same items through the candidate NeMo Guardrails rails and tabulate agreement and disagreement separately for each harm category, for each direction (false blocks and missed blocks). Category-level numbers matter more than a single overall agreement rate, because a category with few examples can hide a large gap.

Decide, for each disagreement pattern, whether to accept it, tune the rail, or escalate it. A missed block in a category that carries regulatory weight usually needs a fix before cutover. A false block that a product owner accepts as a user-experience trade-off can be recorded as accepted, with the named approver and the reason. Write each decision into the calibration record with the rail version, the threshold value, the sample set and the date. Keep this record with the parallel-run results, since reviewers and auditors will ask how thresholds were chosen and whether the choice was deliberate rather than inherited from a vendor default.

What drives effort and duration in this move

This table compares the factors that raise or lower the effort of moving from Azure AI Content Safety to NeMo Guardrails. Read each row against your own inventory of call sites, categories and hosting constraints to see where your move sits. The main takeaway is that the quote follows from the written scope, so the inventory and test data you bring to scoping matter more than any single factor.

DriverWhat raises effortWhat lowers effort
Call sites and categoriesMany applications call Content Safety through separate code paths, each with its own harm category and severity settingsA single gateway or shared wrapper calls Content Safety, with a short list of categories in use
Custom categoriesCustom categories need new classifiers, self-check prompts or Colang flows, each with its own test cases and threshold calibrationCustom categories map onto existing NeMo Guardrails safety models or simple topic rules
Groundedness checks tied to RAGGroundedness is checked against many retrieval sources, chunk formats and citation rules that must be rebuilt as retrieval railsGroundedness applies to one knowledge base with stable chunk structure and clear source attribution
Languages and modalitiesSeveral languages, image inputs or audio need separate models, checks and validation setsText in one language, with image or audio moderation out of scope or handled elsewhere
Target hostingAir-gapped or locked-down VM estates need offline model artifacts, internal registries and separate change controlKubernetes clusters you already operate, with existing ingress, secrets and observability in place
Model hosting and GPU capacitySelf-hosted safety models need GPU nodes, capacity testing and sizing for peak request volumeSmaller models or CPU-friendly checks suffice for the traffic volume, or GPU capacity is already provisioned
Labeled test setNo existing labeled prompts and outputs, so the team builds and reviews a test set before thresholds can be matchedA labeled set from past Content Safety verdicts already exists and covers each category and language
Internal review and change windowsSecurity, legal and model owners must approve each threshold change, and releases follow fixed change windowsNamed approvers, pre-booked review slots and a rollback plan agreed before work starts

What usually goes wrong when Azure safety checks move to self-hosted rails

Most failed moves from Azure AI Content Safety to NeMo Guardrails fail at the seams: category names, thresholds, traffic coverage, configuration conversion, logging and credentials. Each card names one failure point and a prevention step the team can act on before cutover.

Assuming category names carry over

Azure's harm categories and custom categories do not map one to one onto NeMo Guardrails rails or the self-hosted safety models you choose. A category that reads as equivalent may be detected by a different model, with different boundaries and different false positive patterns. Before cutover, write a table that maps each Azure category to a named rail, a model and an owner, and mark every category with no clear equivalent so it is decided, not assumed.

Copying thresholds without calibration

Azure severity levels are not confidence scores from the models you will run, so a severity of 4 in one system does not justify a blocking score in another. Copying a threshold number from the old service often blocks benign traffic or lets harmful content through. Build a labeled sample from your own traffic, measure each rail's false positives and misses at candidate thresholds, and record the chosen values with the reviewer who approved them.

Parallel run too short for rare traffic

A parallel run that covers a few typical working days will miss low-volume but high-impact inputs, such as a specific jailbreak style, a rare language or a seasonal topic. Azure and NeMo Guardrails can agree on common traffic and still diverge on the tail. Ask the product owner which request types matter most, add synthetic and red team cases for them, and keep the parallel run open until those cases have been seen and reviewed.

Colang 1.0 converted without review

Configurations written in Colang 1.0 can be converted to Colang 2.x with the nemoguardrails convert tool, but NVIDIA states that converted configurations still need manual review. Flows that looked correct can change intent matching or fall-through behavior after conversion. Diff the converted files against the originals, run the same test prompts through both versions, and have a second engineer sign off on every flow before the configuration reaches production.

Colang 2 migration guide

Missing logs auditors will ask for

Azure records moderation results in ways many teams never export, and the self-hosted stack does not produce equivalent evidence by default. When an auditor asks which input was blocked, at what score and under which policy version, the team may have no answer. Decide before cutover which fields to retain for each verdict, including rail name, model version, threshold and configuration hash, and confirm the retention period with your compliance owner.

Azure keys left in the old path

Azure endpoint keys and resource credentials often remain in application config, CI variables or old service accounts after the new rails are live. Those credentials keep working and can be used to call the old service outside the review process. Inventory every place the Azure key is referenced, rotate or revoke it after the final cutover, move the remaining secrets into your secrets manager, and confirm the old resource is disabled.

How much effort, time and internal input does this migration need?

What does a migration from Azure AI Content Safety to NeMo Guardrails cost?

No single figure applies, because cost depends on the written scope, not on the tool. NeMo Guardrails is open-source under the Apache 2.0 license, so there is no license fee for the library itself. The paid work is people and infrastructure: someone designs the rails, builds the Colang or Python logic, stands up the self-hosted models, runs the parallel comparison and hands over documentation. Infrastructure for self-hosted safety models is a recurring cost that the buyer pays to a cloud or data center provider. Ask any partner to separate one-time work (inventory, build, testing, cutover) from recurring work (upgrades, model updates, monitoring, retesting) and to show the hours and hosting assumptions behind each line.

How long does this kind of migration take, and what makes it longer?

Duration is set by how many checks must be replaced and how much of the Azure behavior the team must match. The main drivers are the number of Prompt Shields, harm category and groundedness uses, the count of custom categories, the number of applications and endpoints calling the service, and how many severity thresholds need calibration against real traffic. Longer timelines usually come from undocumented thresholds, multiple languages or modalities, and approval cycles for the parallel run. Confirm the schedule against the written scope rather than against a generic estimate.

What does the migration need from our own team?

The work depends heavily on your team's participation. Expect to provide:

  • An inventory of every Azure AI Content Safety call, its settings, and the applications that depend on it
  • Representative prompt and response samples, with labels for what should have been blocked or allowed
  • Test and staging environments with the same network paths as production
  • A named owner who can approve severity thresholds and blocked-message wording
  • Security and compliance reviewers who will accept the evidence before cutover

Without labeled samples, threshold matching becomes guesswork, so ask early what data your team can release.

Can our own engineers do this migration without outside help?

Yes, a capable internal team can do it, provided it has time, skills and a clear sign-off path. The skills needed include Python, container deployment, model hosting, and enough Colang or Python to express rails. Internal teams most often struggle with threshold calibration, parallel verdict comparison and producing evidence that security reviewers accept. A useful test is whether you can name who will own the rails after cutover, who will run upgrades, and who will rerun tests when the models or the NeMo Guardrails release change. The NeMo Guardrails 0.25.0 release requires Python 3.11, 3.12 or 3.13, so confirm your runtime before estimating internal effort.

What should a written quote for this migration include?

A written quote should follow a written scope and list each deliverable separately. Ask for:

  • The Azure features in scope, including Prompt Shields, harm categories, groundedness detection and custom categories
  • The target rails, models and hosting environment, with any model licenses named
  • The number of applications, endpoints and languages covered
  • The parallel-run period, comparison method and acceptance criteria
  • Documentation, handover, and what is excluded
  • Recurring items such as retesting and upgrade support, priced separately from the build
Do we need to keep the Azure AI Content Safety checks running during the parallel run?

Usually yes, because the parallel run is how you prove the new rails match or improve on the old decisions before you switch. Keeping Azure in place lets you record both verdicts on the same traffic and review disagreements. The trade-off is cost and data exposure, since traffic still reaches Azure during that period. Confirm with your privacy and compliance teams whether that data flow is acceptable, and agree on an end date for the Azure calls in the written plan so the overlap does not continue by default.

How DeployOpen scopes, delivers and supports the migration

DeployOpen approaches the move from Azure AI Content Safety to NeMo Guardrails as a written scope: which Prompt Shields, harm category, groundedness and custom category behaviors must be matched, and which self-hosted models and rails replace them. The work runs inside your own infrastructure, with thresholds calibrated against your traffic before any cutover.

How we scope

  • Inventory every Azure AI Content Safety call, category, severity threshold and custom category your application relies on.
  • Map each feature to a NeMo Guardrails input rail, output rail, retrieval rail or custom action, and record gaps in writing.
  • Agree in writing which self-hosted models, hosting environment and Python or Colang version the engagement will cover.

How we build

  • Build the rails configuration in config.yml with Colang files and Python actions, sized to the categories you approved.
  • Calibrate severity thresholds against recorded representative prompts and responses, and document each chosen cutoff.
  • Test blocked and allowed cases, including jailbreak and injection samples, before any traffic moves to the new rails.

How we hand over

  • Deliver the configuration repository, deployment files for the guardrails server, and runbooks for the self-hosted models.
  • Document the mapping from each Azure feature to its replacement, including any behavior that differs and needs your sign-off.
  • Run a supervised cutover with a rollback procedure, and train your team to read rail decisions and adjust thresholds.

How we support

  • Offer ongoing support, upgrades and continuous testing as a retainer, so rail changes are retested after each NeMo Guardrails release.
  • Confirm with your team which NeMo Guardrails version and Colang version your production configuration will target before go-live.
  • Review the NeMo Guardrails upgrade notes and the deprecation of LLMRails before scheduling any version change.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.