Practical RAG evaluation guide

How to evaluate a RAG system before launch

Your prototype says a manager can approve a $120 client dinner. It cites the travel policy. The answer sounds reasonable. Would you let an employee act on it?

To evaluate a retrieval-augmented generation (RAG) system, start with questions your users actually need answered. For each one, check what evidence the system found, what answer that evidence supports, and what the system does when the documents leave the question open. Agree with the people who own the workflow on which mistakes would block a release.

Illustrative example

Start with a decision your users make

In this example, an employee asks, “I’m planning a $120 client dinner. Whose approval do I need before I book?”

Suppose the company travel policy contains these two passages:

Policy sectionWhat it says
§3.1 · Employee meals“Employees may claim up to $75 per person for meals while traveling. A manager must approve exceptions.”
§4.2 · Client entertainment“Client dinners over $100 in total require written approval from the department director before booking.”

Before running the test, ask the policy owner what a usable answer must tell the employee. Here, the employee needs written approval from the department director before booking, and the answer should point to §4.2. Capture those requirements in a short test record. Different wording can still satisfy all of them.

Inspect the evidence behind the answer

Run the question through the application your users will use. Save the passages it retrieved alongside the answer and citation it displayed. Comparing those pieces tells you where to investigate.

What the system retrievedWhat it told the employeeVerdict
Only §3.1, on employee meals“Ask your manager to approve the dinner.”Fail. Retrieval missed the client-entertainment rule. Check whether §4.2 is in the index and whether the search returns it for “client dinner.”
Both §3.1 and §4.2“Ask your manager to approve the dinner.”Fail. The applicable rule reached the model. Investigate why the answer applied the employee-meal rule to a client event.
§4.2“Get written approval from your department director before booking. See §4.2, Client entertainment.”Pass for this question. The answer names the approver, the form of approval, and the timing. The cited passage supports all three.

The first two runs produce the same wrong answer, but they point to different fixes. Keeping the retrieved passages saves the team from guessing which part of the system to change.

Test a question the documents leave open

Now change the amount. “I’m planning a client dinner that costs exactly $100. Whose approval do I need?”

The policy says over $100. Assume the two passages above are the only relevant guidance available. A useful answer would be:

Section 4.2 requires written director approval for client dinners over $100. It doesn’t specify who approves a dinner costing exactly $100. Check with the policy owner before booking.

“No approval is required” would fail. It turns a gap in the policy into permission to act. The example also gives the policy owner useful feedback: employees have a reasonable question that the current document leaves unanswered.

Decide what would block the first release

Build a small test set with the person accountable for the workflow. Include routine questions, exceptions that change the answer, cases the documents leave unresolved, and questions users lack permission to have answered. Record the source version, expected evidence, required answer details, retrieved passages, actual answer, and verdict. Keep the failed cases so you can rerun them after a change.

Set the release criteria around what a user might do next. For this expense-policy pilot, the owner might accept a slightly wordy answer and block release if the system names the wrong approver, invents permission, or reveals restricted information. Review those failures individually. An overall pass rate can hide the one answer that sends an employee to the wrong person.

By the end of the review, the CTO and workflow owner should be able to make a concrete decision: release to a defined group, narrow the questions the pilot supports, or fix a specific failure and test again.

Evaluate a real question

Discuss an evaluation for your RAG prototype

Bring one representative user question, the answer your prototype gave, and the source you expected it to use. We can use that example to scope a focused evaluation with your team.

Discuss your RAG evaluation