5.2 · Advanced level

RAG, embeddings and fine-tuning

Retrieval-augmented generation (RAG) combines information retrieval with generation: it finds documents or excerpts and gives them to a model as context. Embeddings represent information as vectors to support similarity searches. Search may also combine keywords, filters and result reranking.

Quality depends on document preparation, retrieval, permissions and how answers use sources. RAG does not eliminate hallucinations or make documents automatically safe. Fine-tuning changes a model’s behaviour using examples; it is not the same as maintaining an up-to-date document collection.

ILLUSTRATIVE EXAMPLE

In an internal assistant, filter documents by the person’s access rights before passing them to the model. Then test whether the answer relies on the right passages and admits when it cannot find enough information.

Separate retrieval failures, generation failures and authorisation failures.

Try it yourself

Design ten evaluation cases for a document assistant: include an answer that is present, one that is absent, conflicting sources, an outdated document and a document the user is not authorised to read. Define how to distinguish each failure type.

See all AI Literacy topics
A SIMPLE NEXT STEP

It starts with a conversation.

Tell us what your business is trying to solve. The first conversation is free and comes with no obligation.

Request a free conversationOr explore our services
LET’S TALK

It starts with a conversation.

Tell us a little about yourself and your business challenge. The first conversation is free, with no obligation.