What happens when the AI can't answer
Three failure modes — KB misses, complaints, and out-of-policy requests — and the architectural patterns that turn each one into product improvement instead of a customer-service incident.
Most AI demos focus on the happy path — the AI answers correctly, the customer is delighted, the screenshot goes on the homepage. The real product question is: what happens when the AI doesn't know?
Three failure modes, three handlers.
Failure mode 1: The answer isn't in the knowledge base
Customer asks "هل عندكم خصم على الباقات؟" The agent searches the knowledge base, finds nothing about discounts, and has to answer something. The wrong answer here is hallucination — making up a "20% discount available this month!" because that sounds plausible.
The right answer is structural. We give the agent an explicit rule: if the knowledge base returns no relevant results for a substantive question, respond with a graceful "I'm not sure about that — let me get someone to confirm" and automatically create a ticket. The customer's exact question gets logged, a notification fires to the owner, and the owner gets a "Add this answer to KB" button when they review the ticket.
After 30 days of running this, your knowledge base has the answers your customers actually asked for — not the answers you guessed they'd ask.
Failure mode 2: The customer is angry
Sentiment detection runs on every incoming message. When the model flags a message as a complaint (configurable threshold, dialect-aware so "تعبت من هالخدمة" registers correctly in Kuwaiti), three things happen:
- The conversation gets a
complaintflag. - A ticket is auto-created with
type: complaintandpriority: high. - The owner is notified — by WhatsApp template message (so it works even outside the 24-hour Meta window), by webhook (if they have one configured), and by an in-portal banner.
Critically, the AI doesn't stop responding to the angry customer. It downshifts into a calmer, more conservative tone (the prompt has explicit "complaint mode" rules), apologizes, and stays helpful. The human gets the time to review and intervene rather than the customer being silently put on hold.
Failure mode 3: The customer asks for something the AI shouldn't do
Bookings, refunds, account changes, anything that touches money or contracts. We use per-tool access control in the agent itself — the agent only has access to the tools the tenant explicitly enabled. If "process refund" isn't a wired-up tool, the agent literally cannot do it, and its prompt explicitly tells it to escalate.
This is the core principle: don't rely on prompt-level "please don't do X" instructions, because models eventually get jailbroken. Rely on the tool surface — if the tool doesn't exist, the action can't happen.
The aggregate view
All three failure modes converge on the same place: the Knowledge gaps page in the portal. Aggregated, deduplicated, ranked by frequency. Owners can see "37 customers asked about discounts this month, here's the customer phone numbers, click here to add the answer to the KB". This closes the loop — every failure becomes a content improvement, automatically.
That's the part of the AI product most demos skip. The happy path is table stakes. The failure-mode handling is what separates a toy from a production system.
Was this article helpful?
