Gallery inside!
Research

AI Guardrails: When Blocking Harm Also Blocks Useful Work

Compare the safety and usability tradeoffs in AI guardrails, then test whether your controls protect customers without blocking legitimate work.

6

A customer asks your support assistant to help report harassment. Their message quotes what another person said. The safety filter sees abusive language and blocks the request. Your dashboard records a blocked message; the customer still cannot file a report.

Now consider someone asking the same assistant to write an abusive reply. The subject matter overlaps, but the right response is different. One customer needs help documenting harm. The other is asking the product to create it.

This is the difficulty behind choosing AI guardrails. You need to stop misuse while allowing work that may involve sensitive material. You also need a system people can use without repeated refusals, long waits or unnecessary escalation.

No Free Lunch With Guardrails investigates those competing demands. Its useful contribution is to put attack detection, legitimate use and processing time into the same evaluation. The results challenge two convenient assumptions: that the strongest attack score identifies the best safeguard, and that asking a checking model to reason more will reliably improve its judgment.

For a technical or product leader, the research offers a way to ask a better question: which configuration protects this workflow while still letting the intended work get done?

What the Research Actually Shows

The authors distinguish three ways a guardrail can affect a product. It can let harmful material through. It can remove content needed for a useful answer. It can also reject legitimate requests or add enough delay to make the interaction difficult. Their hypothesis is that reducing the first problem necessarily creates costs elsewhere.

That is a stronger claim than saying safeguards sometimes make mistakes. It suggests that choosing a guardrail involves deciding which compromises a particular application can tolerate. The experiments examine those compromises across different systems and instructions. They provide examples of tradeoffs, rather than a proof that every future improvement must make something else worse.

How the researchers tested the problem

The study compares hosted moderation services, open-source safeguards and language models instructed to act as checkers in its evaluation procedure. A base model produces content, a guardrail evaluates it, and the researchers record the decision and processing time. They check whether the system allows or rejects material as expected. For model-based checkers, the researchers also change the moderation instructions.

They test two broad kinds of material. The attack tests include direct harmful requests, attempts to disguise intent, and instructions designed to override the system's rules. A separate collection includes ordinary useful tasks and harmless requests whose subject matter can resemble harmful content. The latter matters because a safeguard can appear effective when it rejects aggressively, yet fail the people who need to discuss a sensitive subject legitimately.

The distinction is easy to see in the reporting example. A test containing only requests to generate abuse would never reveal that the assistant also rejects customers quoting abuse as evidence. Both kinds of request need to be present before the team can judge whether its policy is working.

The study's comparisons reveal two findings worth examining in detail.

1. A stronger attack result does not settle the choice

The attack tests ask whether a checker recognizes harmful material even when an attacker disguises it or tries to override the rules. Two columns in the original results below are particularly useful: SAGE, an adversarial benchmark, and Long, a separate test that places attacks within long inputs. Read across the rows labelled “nemo-guard” and “gpt-4o-detailed.”

In the original attack results, NeMo using GPT-4o-mini scores 0.978 on SAGE and 0.840 on Long. Detailed-prompt GPT-4o scores 0.972 and 0.541. NeMo is also faster in this evaluation: an average checking time of 0.690 seconds versus 1.474 seconds.

The scores describe classification quality on each test: higher is better. They are not percentages of attacks blocked or customers protected. The useful comparison is between configurations within the same column.

Type Model SAGE WildJailbreak Long AJ XTRAM Latency(s)
Open-Source enkryptai-iad-v3 0.896 0.857 0.792 0.991 0.950 0.042
nemo-guard 0.978 0.917 0.840 0.974 0.937 0.690
llama-guard 0.897 0.636 0.494 0.622 0.868 0.959
think-guard 0.963 0.772 0.457 0.748 0.913 0.524
vijil-mbert-prompt-injection 0.938 0.887 0.451 0.851 0.996 0.056
Provider guardrailsai 0.600 0.619 0.710 0.662 0.819 0.348
moderation-api 0.835 0.608 0.432 0.706 0.702 0.283
azure 0.010 0.162 0.773 0.077 0.816 0.070
bedrock 0.922 0.785 0.819 0.994 0.854 0.203
enkrypt-api 0.904 0.843 1.000 0.986 0.941 0.048
LLM-Based gpt-4o 0.940 0.819 0.463 0.903 0.848 1.040
gpt-4o-detailed 0.972 0.909 0.541 0.961 0.915 1.474
gpt-4o-reasoning 0.964 0.897 0.506 0.949 0.922 4.816
gemini-2.0-flash 0.925 0.778 0.432 0.823 0.846 0.420
gemini-2.0-flash-detailed 0.967 0.862 0.482 0.915 0.874 0.593
gemini-2.0-flash-reasoning 0.983 0.895 0.625 0.949 0.936 1.863
claude-3-5-sonnet-latest 0.982 0.906 0.546 0.983 0.933 2.199
claude-3-5-sonnet-latest-detailed 0.987 0.927 0.574 0.990 0.945 4.493
claude-3-5-sonnet-latest-reasoning 0.986 0.895 0.769 0.988 0.960 8.588
mistral-large-latest 0.961 0.782 0.512 0.839 0.908 1.277
mistral-large-latest-detailed 0.978 0.929 0.584 0.963 0.932 1.644
mistral-large-latest-reasoning 0.979 0.842 0.610 0.789 0.932 8.689
Original Table 2 from No Free Lunch With Guardrails, v2. Start with NeMo and detailed-prompt GPT-4o; the last column is average checking time in seconds. The other rows preserve the study’s full comparison. Open the original table and caption. Source: the paper’s authors, CC BY-SA 4.0; table contents unchanged, display reformatted.

That is only half the selection decision. The separate harmless-content tests ask whether useful material can pass. PHTest concentrates on harmless prompts that resemble harmful ones—the kind of distinction a reporting assistant must handle when it encounters sensitive language. In Table 1’s PHTest column, detailed-prompt GPT-4o scores 0.962 against NeMo’s 0.928. The order has reversed.

Type Model PHTest GuardrailsAI Arena Awesome NoRobots Latency (s)
Open-Source iad-v3 0.819 0.584 0.972 0.619 0.960 0.038
nemo-guard 0.928 0.640 0.858 0.900 0.986 1.019
llama-guard 0.971 0.860 0.975 0.972 0.995 1.540
think-guard 0.945 0.895 0.994 0.995 0.994 3.692
vijil-mbert-prompt-injection 0.841 0.686 0.944 0.980 0.958 0.076
Provider guardrailsai 0.917 0.620 0.920 0.777 0.907 0.357
moderation-api 0.896 0.863 0.995 0.998 0.955 0.259
azure 1.000 0.811 1.000 0.995 1.000 0.068
bedrock 0.938 0.553 0.950 0.112 0.978 0.197
enkrypt-api 0.920 0.864 0.976 0.993 0.982 0.053
LLM-Based gpt-4o 0.975 0.871 0.993 0.995 0.999 0.966
gpt-4o-detailed 0.962 0.855 0.990 0.990 0.996 1.272
gpt-4o-reasoning 0.956 0.860 0.985 0.988 0.999 4.295
gemini-2.0-flash 0.963 0.874 0.996 0.998 0.999 0.579
gemini-2.0-flash-detailed 0.957 0.887 0.995 0.998 0.998 0.421
gemini-2.0-flash-reasoning 0.821 0.820 0.971 0.972 0.990 1.837
mistral-large-latest 0.951 0.868 0.992 1.000 1.000 1.341
mistral-large-latest-detailed 0.882 0.852 0.973 0.988 0.997 1.752
mistral-large-latest-reasoning 0.825 0.780 0.940 0.956 0.986 8.856
claude-3-5-sonnet-latest 0.873 0.836 0.985 0.990 0.997 2.161
claude-3-5-sonnet-latest-detailed 0.867 0.832 0.984 0.987 0.994 4.013
claude-3-5-sonnet-latest-reasoning 0.857 0.814 0.989 0.972 0.996 7.881
Original Table 1 from No Free Lunch With Guardrails, v2. Compare the PHTest entries for NeMo and detailed-prompt GPT-4o: the configuration ahead on the selected attack tests is behind here. This table has its own latency measurements. Open the original table and caption. Source: the paper’s authors, CC BY-SA 4.0; table contents unchanged, display reformatted.

The important finding is the reversal. If you selected solely from the attack results, you would miss evidence relevant to legitimate users. If you selected solely from the harmless-content results, you would miss evidence about misuse and delay. Neither result is irrelevant; each answers a different part of the product decision.

For the support assistant, this means a team should inspect both the abusive requests that slip through and the genuine reports that cannot proceed. A candidate that performs better on one may still be the wrong choice if its failures on the other are unacceptable. The team's job is to establish those limits before interpreting a benchmark as a purchasing recommendation.

2. More reasoning can add delay without improving the result

The researchers tested three ways of instructing a model-based checker: a simple moderation directive, more detailed rules, and a prompt asking for step-by-step reasoning before a decision.

This comparison matters because it changes something teams can control directly: the instructions given to the checker. A detailed policy can spell out distinctions that a short instruction leaves implicit. Asking for further reasoning adds another possible intervention, but the experiment shows why it needs its own test.

Return to the three GPT-4o rows in Table 2. Moving from simple to detailed instructions raises SAGE from 0.940 to 0.972 and Long from 0.463 to 0.541. Asking for step-by-step reasoning then lowers those scores to 0.964 and 0.506. Meanwhile, average checking time rises from 1.040 seconds for the simple prompt to 1.474 for detailed instructions and 4.816 for reasoning.

For these two tests, more explicit rules help; the extra reasoning step does not improve on them. That is a useful distinction for a product team deciding whether another few seconds of waiting buys a better decision. These are checking times in the study, not complete customer-response times, and the pattern does not hold in every attack column.

It also does not hold for every model. Gemini 2.0 Flash’s reasoning configuration improves on its detailed prompt in both SAGE and Long. It takes longer, however, and its score on the separate PHTest comparison falls from 0.957 to 0.821. The right conclusion is to test the model, instructions and intended task together. “Ask it to think harder” is not a reliable selection rule.

Our implication for a product team is specific: compare an explicit policy with the existing setup before assuming a more elaborate checking process is worth its cost. Keep any extra step only if the improvement matters for your application and survives the checks on legitimate use.

What the evidence leaves for your team to establish

These are April 2025 configurations, not a current ranking of available products. The researchers are affiliated with Enkrypt AI, whose service is included in the evaluation. The comparisons are useful evidence to investigate, rather than an independent procurement verdict.

The paper's tables also do not show whether a customer finished a report, abandoned the interaction or needed a support agent. They measure classification and delay on the study's test material. Translating that into product value requires observing the complete workflow.

The same distinction applies to long documents. A separate long-input test is useful evidence that a safeguard needs evaluation on that kind of material. It does not tell you how your particular conversation histories or uploaded documents will behave. Those belong in your own test set.

The Core Insight: Define the Behavior You Want to Permit

The reporting example exposes a policy problem before it exposes a model problem. “Reject abusive language” conflicts with “help customers report abuse.” A checker implementing the first rule faithfully can prevent the second task from working.

Start by separating the content being discussed from the action being requested. In a proposed reporting workflow, quoted language is evidence to handle appropriately. Asking the assistant to compose a new abusive message is a different request. The policy needs to explain that distinction, and the checker needs enough context to apply it.

There is a third case to test: a user presents harmful generation as part of a supposedly legitimate report. A label such as “for evidence” should not itself grant permission. The application still needs to inspect what it is being asked to produce.

These distinctions give the team something concrete to evaluate. If genuine reports fail, look at the rule and the material the checker received. Did it see the reporting request, or only the offensive quotation? If disguised generation succeeds, inspect whether the policy treats an asserted purpose as sufficient evidence of legitimacy.

Changing models before answering those questions can leave the underlying ambiguity intact. A more capable checker still needs a policy that expresses the product's intended behavior.

Real-World Applications: Build the Reporting Path Around the Decision

For a support assistant, we would organize the first implementation around four responsibilities.

Establish the requested task. Keep the customer's request distinct from quoted evidence. Give the checker the relevant reporting policy and the context required to interpret it. Test whether the system can distinguish submitting a report from generating further abuse, including attempts to disguise the latter as the former.

Check the assistance being produced. Accepting a legitimate report does not make every possible reply appropriate. The assistant might repeat offensive material unnecessarily or propose a retaliatory response. Check its generated response before showing it to the customer, using rules for acceptable assistance rather than mechanically reapplying a ban on all sensitive language.

Validate the report itself. A permitted conversation can still produce an incomplete submission. Required fields, destination and submission status need checks of their own. Ask for missing information instead of treating an unfinished report as successful. If the assistant can change accounts or issue refunds, keep permission checks for those actions separate from content moderation.

Make rejection and failure recoverable. A genuine customer should have a route to a reporting form or human assistance when the automated path cannot proceed. Keep a checker failure distinct from a policy refusal. Both can interrupt the workflow, but they call for different fixes: one may need a reliability repair, the other a policy or classification change.

This is where the research becomes operationally useful. The team can locate a problem at the request decision, the response, the submission or the recovery step. A single count of blocked messages cannot show which of those responsibilities failed.

Implementation Frameworks

These options support different responsibilities in that proposed workflow. Their current capabilities should be evaluated separately from the paper's historical configurations.

NVIDIA NeMo Guardrails: apply request and response checks

NeMo’s self-check mechanisms can use a model and custom instructions to evaluate user input and generated output. That makes it a candidate when the missing capability is applying the reporting policy at those two points. Its documentation says example prompts need evaluation and customization for production use.

Start with separate rules for acceptable reporting requests and acceptable assistance. Run the three contrasting request types through both checks, inspect the decisions, and measure the resulting customer wait. The goal is a working policy, not merely a configuration that loads.

Also test an unusable checker response. NVIDIA documents that, with its default parser, an empty self-check response after the model exhausts its output allowance causes blocking. Record that as a checker failure and connect it to recovery, rather than reporting it as detected misconduct.

Guardrails AI: combine validation rules where that simplifies the workflow

Guardrails AI supports validators that can be combined into input and output guards. Consider it when you need several validation rules and want a consistent way to apply them.

For the report submission, begin with the required structure and fields. Then identify whether any content validators add a useful check. A structurally valid report can still contain a bad decision, so passing field validation should not count as passing the reporting policy.

This is an optional addition. If your application already checks required fields reliably, retain those checks. Adding another library should solve an identified maintenance or validation problem.

Promptfoo: test attempts to get around the rules

Promptfoo’s red-teaming workflow generates adversarial inputs, runs them against an application and evaluates responses. Use it to probe how the assistant responds when users try to bypass the reporting policy, including attempts framed as legitimate assistance.

Pair those attack cases with representative genuine reports. The attack exercise examines misuse; the genuine reports show whether the application still performs its intended job. Retain useful failures as regression cases so a policy or model change can be compared with the previous setup.

You do not need all three tools for the first evaluation. Keep the existing application as the baseline, introduce the missing check, and add infrastructure only when its role is clear.

Decide Whether the Change Is Worth Keeping

Before adjusting prompts, have the relevant product, support and safety owners agree on expected behavior for the genuine report, abusive-generation request and disguised attack. Include incomplete reports and checker failures. Reserve some cases for the final comparison so the system is tested on more than the examples used to tune it.

Compare the existing setup with the proposed policy under the same cases. Give candidate checkers equivalent material and comparable rules; detecting offensive wording and deciding whether a report may proceed are different tasks. Inspect serious violations that pass, legitimate requests that fail, reports successfully submitted, staff interventions and total waiting time. Keep those outcomes separate: an improvement in completed reports cannot excuse an unacceptable increase in harmful responses.

Inspect failures by request type as well as in aggregate: an overall gain can conceal a newly blocked group of legitimate requests. When a result is poor, investigate the failed case before adding another model call. A missing policy distinction, lost context and an unavailable checker are different defects. The prompt experiment is a reminder that more processing is not automatically the remedy.

Retain the change when it meets the agreed safety requirements and makes the legitimate workflow meaningfully better. If the gains disappear once review effort, recovery and waiting time are included, revise the approach before expanding it.

TechClarity’s View

The strongest lesson from this research is to make useful work part of the safety evaluation from the beginning. Otherwise, a team can improve the number it is watching while making the product less usable.

We would start with an explicit policy, a modest implementation and a test set that represents both misuse and genuine customer work. Add more elaborate checking when it fixes a demonstrated weakness and its benefits justify the delay and operational effort. Keep the policy and evaluation cases usable across vendors so changing a model does not erase what the team has learned.

For the customer reporting harassment, success is an appropriately handled, completed report. A guardrail earns its place by helping the product reach that outcome safely.

Original Research

No Free Lunch With Guardrails — arXiv:2504.00441v2, April 3, 2025. Read the full original research at the link.

Related research

Tags:
Author
TechClarity Analyst Team
September 27, 2026