Moderating AI chat before it reaches your customers
How to check what customers type into an AI chat and what it says back: input and output filters, the streaming trade-off, human handover, and liability.
Westerwick4 min read

On this page
A customer-facing AI chat is your company speaking, in real time, to people you've never met, some of whom will try to make it misbehave. Everything it says, you've said.
Here is how to moderate AI conversations before they reach customers: what to check on the way in, what to check on the way out, the trade-off hidden in fast-typing chat windows, and where a person needs to step in.
You own what your chatbot says
Two well-reported cases make the point.
In 2024, a Canadian tribunal held Air Canada responsible after its website chatbot gave a passenger wrong information about bereavement fares. The airline argued the chatbot was "a separate legal entity that is responsible for its own actions"1. The tribunal disagreed: "It makes no difference whether the information comes from a static page or a chatbot"1. Air Canada was ordered to pay $812.02 in damages and fees1.
The same year, the parcel company DPD "disabled part of its online support chatbot after it swore at a customer"2, who had deliberately coaxed it into criticising the company. DPD said "an error occurred after a system update"2. The damage was reputational rather than legal, but it spread widely.
The lesson from both: moderation reduces risk. It does not move responsibility. That stays with you.
Check what comes in
Some customers will try to make your bot say something it shouldn't. Input checks catch much of that before the model responds.
Amazon Bedrock Guardrails, AWS's moderation layer for AI applications, offers several input checks3:
- Prompt attack detection, for attempts at "jailbreaks, prompt injections, and prompt leakages", meaning attempts to override the bot's instructions.
- Content filters for categories such as hate, insults, sexual content and violence, each with an adjustable strength.
- Denied topics, to keep a support bot away from subjects it shouldn't discuss, such as investment advice.
- Word filters for profanity and "specific custom words such as competitor names"3.
You don't have to use a particular model to use these. The ApplyGuardrail API checks any text "without invoking the foundation models"4. For assistants that look up your documents, you can "evaluate the user input before performing the retrieval"4, so a bad request is stopped before it touches your data.
Check what goes out
Output checks matter just as much, because a model can produce something unsuitable from an innocent question. The same content filters and denied topics apply to responses. Sensitive information filters can detect personal information and either block it or mask it3, so a phone number or ID number in a response is replaced with a placeholder.
For assistants that answer from your documents, Guardrails also offers contextual grounding checks, which flag answers that stray from the retrieved source material3. They're useful, but they're designed for answering from documents, not for free-ranging conversation. We cover grounding and its limits in Bedrock Guardrails for regulated industries.
The streaming trade-off
Most modern chat windows show the answer word by word as it's generated. That feels fast, but it creates a real moderation choice.
In Bedrock's default synchronous mode, guardrails buffer each part of the response and check it "before the response is sent back to the user"5. Nothing unchecked reaches the customer, at the cost of a slightly less instant feel.
In asynchronous mode, text is sent as soon as it's ready and checked in the background. AWS is clear about the consequence: "response chunks may contain inappropriate content until guardrails scan completes"5. Asynchronous mode also "doesn't support the masking of sensitive information"5.
For a customer-facing bot, we recommend the synchronous default. A slightly slower answer is a better trade than a customer seeing something offensive, or someone else's personal details, before it disappears.
A chatbot that pauses for half a second is a design choice. A chatbot that swears at a customer is a news story.
Filters are dials, not guarantees
No filter is perfect. Content filter strength runs from low to high: set it low and harmful content slips through, set it high and ordinary messages get blocked. Personal information detection is probabilistic3. Expect to tune both against real conversations, and expect a determined user to find gaps.
That's why moderation needs two more layers around it:
- A clear handover to a person. When a request is blocked or the bot isn't sure, it should say so politely and offer a human route, not a dead end. Our own website chat is instructed to point visitors to a person when it can't help.
- Review of what was blocked. Look at blocked conversations regularly to tune filters and spot new attack patterns. Be aware that blocked content can appear in plain text in Bedrock's model invocation logs if you have them switched on3. Those logs may contain personal information, so under POPIA they need the same protection as any other customer record.
What to do next
- Decide what your bot must never discuss and set those as denied topics before launch.
- Turn on input and output checks, including prompt attack detection.
- Keep synchronous moderation for anything customer-facing, even if streaming feels slower.
- Design the handover: what the bot says when it's blocked, and how a customer reaches a person.
- Review blocked conversations every week at first, and protect those logs like customer data.
Sources
- 1.Airline held liable for its chatbot giving passenger bad advice - what this means for travellersBBC · 23 February 2024
- 2.DPD error caused chatbot to swear at customerBBC · 19 January 2024
- 3.Detect and filter harmful content by using Amazon Bedrock GuardrailsAmazon Bedrock User Guide
- 4.Use the ApplyGuardrail API in your applicationAmazon Bedrock User Guide
- 5.Configure streaming response behavior to filter contentAmazon Bedrock User Guide


