The most frequent question I get about AI in companies is: “how do I get it to answer on OUR data, without making things up?”. The answer is called RAG (Retrieval-Augmented Generation).
The idea in one line
Before answering, you retrieve from your knowledge base the pieces most relevant to the question and pass them to the model as context. The model answers from the sources, not from memory: fewer hallucinations, citable answers.
hits = store.search(embed(question), k=4) # semantic search
context = join(h.text for h in hits)
answer = llm(f"Context:\n{context}\n\nQuestion: {question}")What you actually need
- Good document chunking (neither too large nor too small).
- A vector store for semantic search.
- Access rules: everyone sees only the documents they are entitled to.
- An evaluation: without measuring relevance and correctness, you do not know if it works.
Where it goes wrong
90% of a RAG’s quality lives in the retrieval stage and data preparation, not in the model. A powerful model on badly indexed data gives confident, wrong answers — the worst kind.
You can try a live mini-RAG, running in your browser, on the Resources page.
Have a cloud or AI project to take to production? I would be glad to talk.


Leave a Reply