Home / Services / RAG to production

RAG to production

An assistant that answers on your documents and cites where each claim came from. Anyone can build the demo in an afternoon; keeping it accurate across thousands of real documents, in several languages and without inventing anything, is a different job.

The problem

Why the demo works and production doesn't

The prototype is tested on five clean documents and ten questions written by whoever built it. In production there are three thousand documents, two versions of the same procedure, scanned PDFs, tables, an internal glossary nobody ever wrote down, and users who ask the way they speak.

That is where the real failures appear: the system retrieves the wrong fragment and answers with confidence, finds nothing because the user used a word that isn't in the document, mixes the old policy with the new one, or replies in one language citing a text in another it didn't quite understand.

The most expensive lesson I learned: a system that always answers is worse than one that knows when to stay quiet. Teaching the assistant to say "this isn't in the documentation" prevents more problems than any gain in fluency.
What's included

The pieces that separate a demo from a product

  • Real ingestion. Scanned PDFs, office files, intranet, email or databases, with cleaning and version control so two truths don't coexist.
  • Chunking with judgement. Splitting by meaning rather than character count, keeping the section title and the context that makes a fragment useful.
  • Hybrid search. Combining meaning with literal matching, because references, codes and technical terms are searched by their exact name.
  • Genuinely multilingual. Asking in one language and finding in another, which is where most implementations fall over.
  • Reranking and citation. Choosing well among what was retrieved and always returning where each claim comes from, so the answer is verifiable.
  • Abstention and guardrails. Letting the system recognise when it has no basis to answer, instead of filling the gap.
  • Continuous evaluation. A suite of questions with the correct answer annotated, run on every change, that warns when something gets worse.
Experience

A multilingual RAG in clinical production

The engine of the platform I co-founded and operate is exactly this, in a domain that does not forgive: retrieving the right knowledge to support a clinical decision, in Spanish, English and Portuguese.

  • Hybrid multilingual search handling the awkward case of asking in one language with literature in another.
  • A suite of nearly 300 cases that runs on every change and catches when an improvement breaks something that worked.
  • Designed abstention: the system flags the case and says so when it lacks sufficient basis, rather than gambling on an answer.
  • All of it on a self-hosted open model, with documentation that never leaves controlled infrastructure.
Questions

Frequently asked

What is RAG and why not train a model?

RAG retrieves the relevant fragment of your documents and gives it to the model to answer with, instead of putting your knowledge inside the model. Far cheaper, updates instantly when a document changes, and lets you cite the source, which is usually non-negotiable professionally.

How many documents do I need?

No minimum: twenty well-chosen ones solve many internal cases, and it scales to tens of thousands. Quality beats volume; contradictory documentation produces contradictory answers and technology doesn't fix that.

Can you stop it hallucinating?

Not entirely, but it drops sharply: require every claim to rest on a cited fragment, allow abstention when retrieval is poor, and measure it with a suite that catches regressions.

What if my documents are in several languages?

It's one of the points where most systems fail, and it's solved with multilingual embeddings and hybrid search. I've run it in production across three languages.

How long does it take?

Two or three weeks over a bounded corpus, answering and evaluated. What stretches projects is almost never the AI: it's access permissions and deciding which version of each document is authoritative.

Got documentation nobody can find?

Tell me what the documents are, who consults them and what they ask. I'll tell you whether RAG is the answer, what it would take and how long.