RAG or fine-tuning: how to specialise AI for your business

RAG gives AI access to your documents; fine-tuning changes the model itself. The first suits knowledge that changes, the second suits ways of working. Here is how to choose.

Two ways to make AI useful

A general-purpose large language model (opens in a new tab) knows nothing about your procedures, customers or vocabulary. Two techniques close the gap: RAG, which hands it the right documents when it answers, and fine-tuning, which retrains it on selected examples.

They are not rivals. In most projects we start with a RAG assistant and consider fine-tuning when style or accuracy is no longer enough.

RAG: answers grounded in your documents

RAG (Retrieval-Augmented Generation) was described in 2020 in a research paper from Meta AI (opens in a new tab). Your documents are split and indexed; for each question, the relevant passages are retrieved and passed to the model with the question.

Its strengths: answers cite their sources, documents can be updated without retraining, and access rights can be respected. It is ideal for internal procedures, contracts and knowledge bases.

Fine-tuning: a way of working

Fine-tuning continues a model’s training on your own examples. Methods such as LoRA (opens in a new tab) make it affordable by changing only a small part of the model.

It helps when the model must adopt a precise style, follow a strict output format or master very specialised vocabulary. It requires a high-quality dataset, built and checked with your experts.

How to choose

  • Your information changes often: choose RAG.
  • You need to cite sources: choose RAG.
  • The model must write in a very precise format or style: consider fine-tuning.
  • You want your own model, hosted in-house: combine fine-tuning with self-hosted AI.

What about privacy?

Either way, your data stays under your control if the model is hosted by you or a European provider. The GDPR (opens in a new tab) applies as soon as personal data is involved, in training and in use. We cover this in our article on AI and the GDPR.

Frequently asked questions

Is RAG cheaper than fine-tuning?

Usually, to get started, because it needs no training. Fine-tuning needs a dataset and GPU time, but can lower the cost of each answer later.

Can RAG and fine-tuning be combined?

Yes. A model fine-tuned for your style can be fed your documents through RAG. That is the approach we took for LegisBox.

Related services

  • AI assistants on your data

    A RAG assistant answers your team’s questions using only your documents and shows where each answer comes from.

  • Model fine-tuning

    Fine-tuning specialises an open-source model in your field: your vocabulary, your style, your tasks.

  • Dataset creation

    A model is only as good as its data.

Let’s talk about your project

A free first conversation, with no commitment, to see what would really help your business.