cd /news/ai-agents/why-your-rag-chatbot-gives-wrong-ans… · home › topics › ai-agents › article
[ARTICLE · art-178260] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=· neutral

Why your RAG chatbot gives wrong answers (and 4 fixes that actually work)

A developer at Sofi Technologies published a breakdown of why RAG chatbots return wrong answers, attributing most failures to four causes: fixed-size chunking that splits tables and headers, pure vector search missing exact terms, weak grounding prompts that let models fill gaps, and testing only with questions the builder already knows. The fixes include hybrid BM25-plus-vector retrieval with reranking, stricter grounding prompts, and a 20–50 question regression test set run after every change. The developer also released ChatbotScore, a free no-signup tool that scores bot answers against source facts and flags the likely cause.

recommendation

Combine BM25 and vector search, dedupe and rerank to the top 5, and rerun a 20–50 question test set after every doc, prompt or model change.

more in playbook: Retrieval and RAG
by read3 min views1 publishedNov 29, 2026

Someone asks your support bot: "How much is shipping on a $40 order?"

Your shipping page says: $9.95, free over $50.

Your bot says: "Shipping costs vary depending on the product. Please contact us for details."

Nobody touched the model. The page is in the knowledge base. So why is the bot wrong?

From building and testing these bots, I've found that almost every wrong answer comes from one of four places. And swapping to a bigger model fixes none of them.

RAG systems split your documents into chunks before searching them. A common default is "every 500 characters".

Now picture your shipping table:

| Order total | Shipping |
| Under $50   | $9.95    |
| $50+        | Free     |

A fixed-size splitter can cut that table down the middle. The bot gets one chunk with "Under $50" and another with "$9.95" and "Free", without the headers. It can't put them back together, so it hedges.

Fix:

Pure vector (embedding) search is good at meaning and bad at exact terms. Ask about "XR-200 battery warranty" and it may happily return a general blog post about batteries.

candidates = bm25.search(q, k=20) + vectors.search(q, k=20)
candidates = dedupe(candidates)
top = reranker.rank(q, candidates)[:5]
answer = llm(prompt(q, top))
log(q, [c.id for c in top], answer)

If your prompt is "You are a helpful assistant. Use the context below.", the model treats the context as a suggestion. When the context is thin, it fills the gap with something that sounds plausible.

"I don't know, let me connect you with the team" costs you nothing. A wrong refund window can cost you a chargeback.

Most bots get tested with questions the builder already knows the answer to: "What are your opening hours?" They pass, and go live.

Real customers ask:

Fix: build a small test set of 20–50 real questions (from support emails, chats and reviews), each with the correct answer from your own pages. Run it after every change: new docs, a new prompt, a new model. Track the score over time.

This turns "I think it's better" into "it went from 31 of 50 to 44 of 50".

Symptom Likely cause
Answer is about the wrong topic Retrieval
Answer is partly right, but cut off or mixed up Chunking
Answer has numbers or facts that aren't in your docs Grounding
Bot dodges ("please contact us") when the answer exists Retrieval or testing

I built a small free tool for exactly this: ChatbotScore. Paste a few questions, what your bot answered, and the correct info from your site. It scores each answer, flags made-up or missing facts, and points to the likely cause above. No sign-up.

I'm a developer at Sofi Technologies. I build RAG assistants that answer from a company's own docs and data, and fix ones that don't. If you'd like help with yours, here's how to work with me.

── more in #ai-agents 4 stories · sorted by recency
── more on @sofi technologies 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/why-your-rag-chatbot…] indexed:0 read:3min 2026-11-29 · —