RAG for Customer Support: Architecture, Examples, and Best Practices

Rajni

Written by

Rajni
Himanshu

Reviewed by

Himanshu

Published 01 December 2026

Expert Verified

<p>RAG for customer support, showing knowledge sources, retrieval and search, a verified support response, a customer support agent, and an AI assistant robot.</p>

Summarize this post with AI

Quick Answer

Retrieval-augmented generation (RAG) helps a customer support chatbot answer questions using your company’s approved content. First, it indexes sources such as help articles and policies. When a customer asks a question, it retrieves relevant passages and uses them to draft a reply. If the sources don’t support an answer, the chatbot should ask for clarification or hand off to a person.

TL;DR

  • Keep your sources current. Update and reindex help articles when policies or product details change.
  • Use hybrid search. Combine keyword and semantic search so the chatbot can match exact error codes and understand questions phrased in different ways.
  • Check answers against sources. Link to the relevant article, enforce access permissions, and pass the conversation context to a human agent when escalating.
  • Start with one common issue. Test with real customer questions and measure retrieval and answer quality separately before expanding.

Customer support chatbots need accurate information to answer questions about products, refunds, policies, and technical issues. But when this information is spread across multiple documents or keeps changing, chatbots can struggle to provide the right answers.

Retrieval-Augmented Generation (RAG) helps address this problem by allowing AI chatbots to retrieve relevant information from a company’s knowledge base before responding. This helps provide answers based on actual company information rather than relying only on the AI model’s existing knowledge.

The quality of that answer depends on what the chatbot finds and how it uses it. This guide explains how RAG works in customer support, what the architecture looks like, and what teams can learn from LinkedIn and DoorDash. It also covers how to test answers and when to hand off to a human agent.


What is RAG for Customer Support?

Diagram showing how customer support RAG retrieves information from FAQs, help articles, and policies, then adds it as context to generate an answer.

Retrieval-Augmented Generation (RAG) is an AI approach that helps customer support systems provide answers using information from a company’s knowledge base. Instead of relying only on what a language model already knows, RAG retrieves relevant information from sources such as FAQs, help center articles, product documentation, and company policies before generating a response.

RAG works through three main steps:

  1. Retrieve: The system searches the company’s knowledge base to find information relevant to the customer’s question.
  2. Augment: The retrieved information is added to the customer’s question as context for the AI model.
  3. Generate: The AI model uses that context to create a response based on the available company information.

Example: Handling a Customer Refund Question

Suppose a customer asks:

“Can I cancel my annual subscription and receive a refund?”

Instead of generating an answer from general knowledge, the RAG system searches the company’s documentation and retrieves relevant information, such as:

  • Cancellation policy
  • Refund eligibility rules
  • Annual subscription billing terms

The AI uses this information to explain the refund conditions or directs the customer to a human agent if the available details are insufficient. RAG helps provide answers grounded in company information, but accuracy still depends on the quality and relevance of the retrieved content.


Benefits of RAG for Customer Support

Customer support teams often manage large amounts of information, including product documentation, FAQs, troubleshooting guides, and company policies. RAG helps AI support systems find and use this information to answer customer questions without relying entirely on the model’s existing knowledge.

Here are the key benefits of using RAG in customer support:

1. Answers Based on Company Knowledge: RAG retrieves information from a company’s approved knowledge sources before generating a response. This helps AI support systems provide answers based on actual product details, policies, and support documentation rather than relying on general knowledge.

2. Easier Knowledge Updates: When a company updates its policies, pricing, or product documentation, the changes can be reflected in the RAG system by updating and reindexing the relevant content. This avoids the need to retrain the AI model whenever company information changes.

3. Consistent Information Across Support Channels: RAG allows different support channels, including website chatbots, email assistants, and internal support tools, to retrieve information from the same knowledge base. This helps maintain consistency in the information customers receive across channels.

4. Source References for Better Transparency: RAG systems can provide links or citations to the documents used to generate an answer. This allows customers and support agents to verify information, particularly when dealing with refund policies, billing terms, or technical instructions.

5. Better Access to Large Knowledge Bases: As businesses grow, finding information across hundreds or thousands of documents becomes difficult. RAG makes large knowledge bases searchable, helping AI systems retrieve relevant details from product manuals, troubleshooting guides, FAQs, and help center articles.

However, RAG does not guarantee accurate answers or eliminate hallucinations. Its effectiveness depends on the quality of the knowledge sources, how relevant information is retrieved, and how the AI generates responses from it.


RAG Architecture in Support Chatbots

A RAG-powered support chatbot works through two main pipelines: knowledge indexing and response generation. The first prepares company information so the system can search it. The second retrieves relevant information whenever a customer asks a question and uses it to generate a response.

Pipeline 1: Knowledge Indexing

This pipeline prepares company documentation before customers start asking questions. It helps organize information so the chatbot can retrieve relevant content.

Step 1: Collect Knowledge Sources

The system gathers information from help center articles, FAQs, product documentation, company policies, troubleshooting guides, and approved support records.

Step 2: Clean and Organize Content

Duplicate, outdated, and irrelevant information is removed. Conflicting documentation should also be reviewed to prevent the chatbot from retrieving incorrect or inconsistent details.

Step 3: Split Documents into Chunks

Long documents are divided into smaller, meaningful sections called chunks. This allows the system to retrieve specific information instead of processing entire documents for every question.

Step 4: Create Embeddings and Index Content

The system converts text chunks into numerical representations called embeddings, which help identify content with similar meanings. These are stored in a vector index, often alongside a keyword index for exact-term searches.

Step 5: Add Metadata

Each chunk can include details such as product name, language, region, document version, and access permissions. These details help the system filter information and retrieve content relevant to the customer’s request.

Pipeline 2: Retrieval and Response Generation

This pipeline runs when a customer sends a message. It retrieves information from the prepared knowledge base and uses it to generate an answer.

Step 1: Understand the Customer’s Question

The system identifies what the customer is asking. For follow-up questions, it can use previous messages to form a clearer search query.

Step 2: Retrieve Relevant Information

The system searches the knowledge base using semantic search, keyword search, or a combination of both to identify relevant passages.

Step 3: Rerank Search Results

When reranking is enabled, a second model evaluates the retrieved passages and places the most relevant information first.

Step 4: Build the Context

The selected passages, customer question, and response instructions are provided to the language model. Instructions can require the model to use retrieved evidence, cite sources, and acknowledge missing information.

Step 5: Generate the Response

The language model creates an answer using the retrieved content rather than relying only on its pretrained knowledge.

Step 6: Validate the Response

Where configured, automated checks assess whether the response is supported by the retrieved information and complies with company rules. These checks reduce risk but cannot guarantee correctness.

Step 7: Respond or Transfer to Human Support

If sufficient information is available, the chatbot responds to the customer. Otherwise, it can request clarification or transfer the conversation to a human agent, ideally including the conversation history and relevant context.


Common RAG Components and Their Challenges

Each component of a RAG system plays a role in retrieving information and generating customer support responses. However, problems at any stage can affect the accuracy and reliability of the final answer.

ComponentPrimary FunctionCommon Challenge
Knowledge BaseStores company information, policies, and documentationOutdated, duplicated, or conflicting information
ChunkingDivides large documents into smaller searchable sectionsImportant context gets separated or lost
RetrievalFinds relevant information based on customer questionsRetrieves unrelated content or misses exact terms
RerankingPrioritizes the most relevant retrieved passagesRelevant information gets ranked too low
LLM and PromptGenerates responses using retrieved informationProduces incorrect or unsupported answers
GuardrailsCheck responses against defined rules and policiesFail to detect unsupported or non-compliant responses
Human HandoffTransfers unresolved conversations to support agentsCustomer history and context are lost during transfer
Embedding ModelConverts text into numerical representations for semantic searchFails to capture domain-specific terminology or meaning
Metadata and Access ControlFilters information by product, region, language, and user permissionsIncorrect filters expose restricted content or exclude relevant information
Knowledge Updates and IndexingKeeps searchable content aligned with the latest documentationUpdated or deleted documents are not reflected in search results

Understanding these challenges helps businesses identify where their RAG systems need improvement. Reliable customer support depends on accurate knowledge sources, effective retrieval, response validation, and a clear process for handling unresolved questions.


Real-World Examples of RAG in Customer Support

RAG infographic showing faster issue resolution at LinkedIn and fewer hallucinations at DoorDash.

Several companies have published how they built and tested RAG for support, serving customers, agents, or internal teams. The examples below cover LinkedIn, DoorDash, Elastic, Minerva CQ, and Uber, plus Air Canada as a cautionary case that isn’t documented as RAG. Results are each company’s own reports, so treat them as indications rather than benchmarks.

LinkedIn: keeping the structure of past tickets

LinkedIn’s engineers published a paper at SIGIR 2024 on a customer service question answering system that combines RAG with a knowledge graph. Instead of chopping past tickets into arbitrary text pieces, the system builds a graph from historical issue tickets that keeps the structure inside each ticket and the links between tickets. When a new question arrives, it retrieves the relevant part of that graph.

The authors report that the system was used within LinkedIn’s customer service team for about six months and reduced median per-issue resolution time by 28.6%. The lesson is worth borrowing even if you never build a graph: how you split and organize your content shapes what the bot can find. Keep in mind that this is a result reported by the authors for their own team and data, so your numbers will differ.

DoorDash: RAG with a safety net

DoorDash wrote about its Dasher support chatbot in September 2024. Its older automation followed pre-built flows that handled only a small share of issues, and its help articles were hard to search, slow to read, and written in English only.

Their RAG pipeline works like this: summarize the whole conversation to pin down the core problem, find similar past cases that were resolved using knowledge base articles, drop the matching article into a prompt template, and generate a tailored reply. DoorDash was also candid about what went wrong. Some replies sounded natural but drifted from the source material, so the team added two layers of protection.

  • A guardrail: A cheap similarity check compares each reply with the article text. Replies that get flagged go to a second, LLM-based check for groundedness, coherence, and compliance. A reply must pass to reach the customer, and the team notes that defaulting to a human agent is a sensible fallback.
  • A judge: An LLM-based monitor scores conversations on five areas (retrieval correctness, response accuracy, grammar, coherence, and relevance), with human reviewers calibrating it. DoorDash also runs prompt changes through a test suite to catch regressions.

DoorDash reports that the guardrail reduced overall hallucinations by 90% and potentially severe compliance issues by 99%. Those are the company’s own figures, and the post doesn’t publish the baseline or measurement details, so treat them as an indication of direction, not a benchmark.

Air Canada: what a wrong answer costs

In February 2024, a Canadian tribunal ordered Air Canada to compensate a customer who had relied on the airline’s website chatbot. The bot told him he could buy a full-price ticket and claim a bereavement discount afterward. The airline’s actual policy didn’t allow that. Air Canada argued it shouldn’t be held responsible for what its chatbot said, and the tribunal disagreed.

Public reports don’t describe how that chatbot was built, so this isn’t a RAG case study. It still teaches two useful things. First, the tribunal rejected the idea that the chatbot was a separate entity responsible for its own words, as the tribunal member described the airline’s position. Second, it pointed out that the airline never explained why customers should trust a policy web page over the bot, according to a legal analysis of the decision. A link to the right page doesn’t excuse a wrong answer. When your bot answers a customer, the customer treats it as your company speaking.

Elastic: Building a technical support assistant with RAG

Elastic’s Field Engineering team built the Elastic Support Assistant and documented it in a multi-part series. Among other reasons, the team chose RAG over fine-tuning because its content is mostly unstructured, RAG can use up-to-date documents, and access can be limited by user role. The knowledge library covers more than 300,000 documents.

The first version used hybrid search (keyword plus semantic) and sent only the top three results to the model. Part 4 shows where it fell short. Questions about specific vulnerability codes (CVEs) returned one relevant article out of three, and a question comparing two versions pulled in unrelated pages, so the bot answered as if those releases didn’t exist. The team boosted title matches, generated better summaries, collapsed duplicate article versions, and boosted version numbers mentioned in questions. On its own test set of about a dozen questions, Elastic reports a 78.41% average gain in top-three precision. The set is small, several questions didn’t change, and Elastic sells search software, so treat the figure as a demonstration of method, not a benchmark. The lesson matches best practice 3 below: check what was retrieved before you blame the model.

Minerva CQ: RAG that helps agents instead of customers

Minerva CQ builds an AI copilot that supports human agents during live conversations. Its research paper, written with an Arizona State University researcher, says a standard RAG setup struggled in real-time use because queries were poorly formed and the same frequent questions kept being retrieved. The fix: the system suggests likely questions to the agent, returns a stored answer instantly when one matches an FAQ, and sends everything else to RAG with a cleaned-up query.

The paper reports answers reaching agents within about two seconds and says handling time and costs fall. Two of the three authors work at the vendor, and the abstract gives no figures for those savings. The design lesson: RAG doesn’t have to answer everything, and a person between the AI and the customer limits the damage of a wrong suggestion.

Uber: RAG for internal engineering support

Uber built Genie, an on-call copilot that answers engineers’ questions in internal Slack channels, which see around 45,000 questions a month. Uber chose RAG over fine-tuning because it could launch without a curated set of training examples. Genie sends each retrieved chunk to the model with its source URL, answers only from those chunks, draws only on documents most engineers can access, and gives users feedback buttons and a route to the on-call engineer.

Uber reports 154 channels, 70,000+ questions answered, a 48.9% helpfulness rate, and an estimated 13,000 engineering hours saved. These are Uber’s own estimates, and the post doesn’t say how the helpfulness rate is calculated. A 2025 follow-up found significant gaps when Genie was tested on security policy PDFs, partly because tables lost their structure. After changes such as query rewriting, hybrid retrieval, and table-aware processing, Uber reports a relative 27% rise in acceptable answers and a 60% drop in incorrect advice, with no baseline figures.


Best Practices for RAG in Customer Support

These eight practices draw on the examples above and on published vendor, research, and security guidance. They roughly follow the pipeline, from your content through retrieval and answers to safeguards and measurement. Where a practice rests on a company’s own results, the text says so.

1. Fix the knowledge base before you touch the model

DoorDash calls its knowledge base the foundation for the chatbot’s answers, and it lists an insufficient knowledge base among its main quality problems, next to inaccurate retrieval, hallucination, and weak prompts. Reviewing conversation quality led its team to rewrite misleading terms in articles.

In practice: give every topic an owner, show last-updated dates, retire old pages instead of leaving them live, and write articles that answer one question each, including the conditions that change the answer, such as plan, region, or order date.

2. Turn the chat into one clear search query

DoorDash stresses that the system must understand the customer’s problem before it can retrieve anything useful, and that the conversation summary has to be accurate for the rest of the pipeline to work. A follow-up like “what about the blue one?” is useless as a search query. Rewrite it with the earlier messages included, then search.

3. Use hybrid search, not meaning-based search alone

Embedding search is good at finding content with a similar meaning. It can miss exact strings. Anthropic gives a support-style example: a customer searches for an error code, and a meaning-based search may return articles about error codes in general but miss the one with that exact code. Keyword search (BM25) catches exact matches.

Hybrid search runs both and merges the results. Microsoft’s documentation describes hybrid queries as running full-text and vector search in parallel and merging them with Reciprocal Rank Fusion. In Anthropic’s tests, embeddings plus BM25 beat embeddings alone.

4. Make the bot answer only from its sources, and show them

Write the prompt so the model must base its answer on the retrieved passages and say when they don’t contain the answer. Return the source link with each reply. This helps customers and your own reviewers see where an answer came from. As the Air Canada case shows, a source link is a safety net, not a substitute for accuracy.

5. Check the reply before the customer sees it

Generation can still drift from the sources. DoorDash’s two-tier guardrail is a practical pattern: run a fast, inexpensive similarity check on every reply and reserve a slower LLM-based check for the ones that get flagged. The team found that a more sophisticated guardrail model took too long and used too many tokens to be practical, which is a useful reminder to budget for latency.

6. Make handoff easy and carry the context over

Gartner surveyed 3,566 B2B and B2C customers in February and March 2026. It found that 50% said generative AI makes their interactions easier, yet 87% said access to a human agent is essential when companies use it. Gartner advises against making GenAI a mandatory first step for every issue. A separate Gartner release from September 2026 reported that only 27% of customers would try a chatbot again after a negative experience.

The takeaway: show a visible path to a person, and send along the conversation and anything the bot already collected so customers don’t repeat themselves. For more on balancing the two, see Delta4’s comparison of AI chatbots and live chat.

7. Enforce permissions and treat retrieved text as untrusted

RAG creates a new place for data to leak. OWASP’s guidance on vector and embedding weaknesses (first published in its 2025 list) warns that weak access controls can expose sensitive information stored as embeddings, that shared databases can leak context between users, and that poisoned documents can steer outputs. Its recommendations include permission-aware vector stores and validating the sources that go into your knowledge base.

OWASP’s 2026 edition, released in August 2026, kept prompt injection at number one and sensitive information disclosure at number two. Its project leads’ advice is to design the surrounding system so that nothing important breaks when the model is fooled.

In practice: filter results by the customer’s permissions at retrieval time (not just in the prompt), keep internal-only documents out of customer-facing indexes, and review any user-generated content before it enters the knowledge base, since text can carry hidden instructions.

8. Measure retrieval and answers separately

If a reply is wrong, you need to know whether the search failed or the writing did. Open-source evaluation tools such as Ragas offer standard metrics for this. As described in NVIDIA’s documentation, faithfulness checks whether the response is consistent with the retrieved context, context precision looks at how many retrieved chunks are relevant, and context recall looks at how much of the needed information was retrieved. Answer relevancy checks whether the reply addresses the question.

Metrics need a human check next to them. DoorDash pairs automated scoring with a human review team and regression tests. Build your own test set from real recent tickets, run it every time you change content, prompts, or models, and read a sample of live conversations each week.


How to Evaluate a Customer Support RAG System

Evaluate your RAG system at three levels. Did it find the right information? Did it use that information correctly? Did the customer get their issue resolved? Measuring each level separately helps you pinpoint what to fix. For example, a wrong refund answer could come from an outdated policy in the index or from a chatbot that misread the current one.

1. Retrieval Quality

For each test question, identify the current article or policy passage that supports the correct answer. Then check what the system retrieves.

MetricWhat it measures
Precision@KThe share of the top K results that are relevant. If two of the top five passages are relevant, precision is 40%.
Recall@KThe share of known relevant passages found in the top K results.
Ranking qualityHow high the most useful passages appear in the results.

Check retrieval at the level your system uses. Finding the right help article can still lead to a wrong answer if the retrieved passage leaves out the policy exception the customer asked about.ves incorrect or incomplete information, the final answer may be unreliable.

2. Answer Quality

When retrieval succeeds, check how the chatbot uses the passages it receives.

MetricWhat it measures
FaithfulnessAre the claims supported by the retrieved passages?
Factual accuracyDoes the answer match the verified answer and current policy?
Answer relevanceDoes the reply address the customer’s question?
Citation accuracyDoes each cited source support the claim it accompanies?

Track faithfulness and factual accuracy separately. A chatbot can quote an outdated policy faithfully and still give the customer the wrong answer. Tools such as Ragas can help automate parts of evaluation. Use human review for sensitive or ambiguous cases, such as disputed refunds or account access.

3. Customer Support Outcomes

Once the chatbot is live, measure what happens across the conversation.

Build a Test Set You Can Reuse

Start with real support questions. For each one, record the expected answer, the source passage, and the expected action: reply, ask for clarification, or hand off. Include follow-up questions, exact error codes, conflicting policies, and cases where the knowledge base has no answer.

Run the same tests after changing your knowledge base, prompts, retrieval settings, or model. If a test fails, inspect the retrieved passages first. That tells you whether to fix the content or search before changing how the chatbot writes its answer.


Frequently Asked Questions

Does RAG completely prevent AI chatbots from giving wrong answers?

No. RAG helps reduce incorrect or unsupported answers by retrieving information from company documents before generating a response. However, the chatbot can still retrieve outdated information, misunderstand the context, or generate an answer that is not supported by the sources. Regular testing, knowledge base updates, and response validation help reduce these risks.

What type of data should I use to train a RAG customer support chatbot?

A RAG chatbot can use help center articles, FAQs, product manuals, troubleshooting guides, company policies, and approved historical support tickets. The most important factor is data quality. Documents should be accurate, regularly updated, and relevant to the questions customers ask. RAG typically indexes this information for retrieval rather than using it to train the underlying language model.

Can a RAG chatbot answer questions about orders, refunds, or customer accounts?

Yes, but it depends on the question. RAG can retrieve general information about refund policies, billing terms, and order procedures. However, checking an individual order’s status, verifying refund eligibility, or accessing account details usually requires integration with a CRM, billing platform, or order management system through authorized APIs.

Do I need a vector database to build a RAG chatbot?

Not necessarily. RAG requires a way to retrieve relevant information, but a dedicated vector database is not mandatory. Depending on the knowledge base, businesses can use keyword search, vector search, or hybrid search. Hybrid retrieval can be particularly useful when customer questions contain exact product names, error codes, or technical terms.

Is RAG better than fine-tuning for customer support?

RAG is generally more suitable for answering questions based on frequently changing company information, such as policies, pricing, and product documentation. Fine-tuning is more useful for adjusting a model’s behavior, response style, or performance on specific tasks. Businesses can also combine both approaches when necessary.

How do I know if my customer support RAG system is working correctly?

Test the system using real customer questions and check whether it retrieves the correct documents and generates answers supported by those sources. Useful evaluation measures include retrieval relevance, context recall, faithfulness, and answer relevance. Customer satisfaction, resolution rates, and escalation rates can also help assess its performance in actual support conversations.

When should a RAG chatbot transfer a conversation to a human agent?

A chatbot should offer human assistance when it cannot find reliable information, retrieves conflicting policies, or encounters a request requiring account verification, approval, or human judgment. Customers should also be able to request a human agent directly. During handoff, the system should transfer the conversation history and relevant details so customers do not have to repeat their questions.


Conclusion

RAG can improve customer support when the chatbot finds the current policy, applies it correctly, and knows when to hand off. Start with one common issue, such as refund questions, and test it with real conversations before expanding.

Include an exception in your test set, such as a refund request outside the standard window. If the chatbot misses the exception, check what it retrieved. If it found the right passage but applied it incorrectly, fix how it uses the source. If eligibility depends on order details it can’t verify, hand off the conversation with the context intact.

Expand to the next support issue once the chatbot handles both routine questions and exceptions reliably. A successful rollout gives customers the right answer or gets them to someone who can help.

Share

Tags

AI ChatbotsAI Customer SupportKnowledge BasesRAGRAG Evaluation
Rajni

Article by

Rajni

AI & Tech | Senior Content Writer

Rajni is a senior content writer at Delta4 Infotech covering AI agents, automation, and no-code tools. She writes across the AI space, from chatbots and customer support to MCP and agent workflows, focused on how businesses actually put these tools to work.

Related posts

MCP Tool Poisoning: Attack Examples, Detection, and Prevention
AI Tools

MCP Tool Poisoning: Attack Examples, Detection, and Prevention

Quick Answer MCP tool poisoning is a form of indirect prompt injection. A tool’s description or schema contains instructions that can influence an AI agent when the client passes that metadata to the model. The agent may disclose sensitive data or misuse another connected tool without ever calling the poisoned tool. Review raw tool definitions [&hellip;] Share this: Share on X (Opens in new window) X Share on Facebook (Opens in new window) Facebook

HimanshuHimanshu·30 Nov 2026
Computer-Use Agents Explained: How AI Operates Your Apps
AI

Computer-Use Agents Explained: How AI Operates Your Apps

Quick Answer A computer-use agent is an AI system that operates apps through their on-screen interfaces. The AI model looks at the screen and chooses the next step. A connected tool performs the action, such as clicking a button or typing into a form. The agent then checks what changed before continuing. For example, it [&hellip;] Share this: Share on X (Opens in new window) X Share on Facebook (Opens in new window) Facebook

RajniRajni·30 Nov 2026
What Is AI Slop? Examples, Risks, and Content Quality Standards
AI

What Is AI Slop? Examples, Risks, and Content Quality Standards

Quick Answer AI slop is low-quality AI-generated content produced in bulk with little review. It can look polished while repeating familiar points, making unsupported claims, or showing inaccurate details. Before publishing AI-assisted content, check that its claims are accurate, that it answers the reader’s question, and that it adds something useful, such as a firsthand [&hellip;] Share this: Share on X (Opens in new window) X Share on Facebook (Opens in new window) Facebook

HimanshuHimanshu·28 Nov 2026