AI & XML / RAG benchmarking / REST API tests

With 939 questions, fully manual checking is possible but laborious. If the RAG system offers a REST API or comparable interface, much of the test run can be automated.

How an automated test works

  1. Import the benchmark document into the RAG system.

  2. A test program reads the selected questions from the catalogue.

  3. Send each question to the system through the REST API.

  4. Store answers, sources, locations, runtime and technical metadata.

  5. Compare results with expected answers and acceptance criteria.

  6. Aggregate points by category, priority and weight.

  7. Flag unclear answers for manual review.

What can be checked automatically

Exact information such as names, numbers, page references, table values, citations or statements that information is absent can often be assessed by rules. More freely worded answers can be compared semantically with expected answers and acceptance criteria.

Each run can store, among other things:

  • the system’s answer text

  • cited source and document location

  • response time and error status

  • model and system versions used

  • retrieval results, if exposed by the API

  • content points, evidence points and comments

Repeatable regression tests

An automated benchmark can run again after every technical change. It reveals whether a new language model, embedding model, chunking strategy or image analysis improves or worsens particular categories.

Repeating the same questions also reveals stability. A table question should not be answered correctly once and return a different value or source on the next run.

The benchmark therefore supports both one-time provider selection and ongoing quality tests for development and updates.

Automation does not replace every expert review

Automatic scoring is very reliable for clear expected values. Expert sampling remains useful for complex or free-form answers, especially when multiple phrasings are acceptable, an answer is partly correct or a formally present citation is substantively inappropriate.

A sound procedure combines automated runs with targeted human review of borderline cases.

back to top