Fine-Tuning vs RAG vs Prompting: When to Use Which?
Prompting, RAG or fine-tuning: what each one changes, which to try first, and how to explain it in your AI interview.
In short
Try prompting first, because it is the cheapest and quickest fix. Add RAG when the model needs facts it does not have, and fine-tune only when its style or format stays inconsistent after that.
10 min readIntermediateVery common · estimateFacts checked 26 November 2026
Say it out loud
Read it once, then say it without looking. Start with the short one; use the long one when they ask you to go deeper.
I try the cheapest fix first. That's prompting: clearer rules and a few examples. If the model is missing facts, like a bank's fee sheet that changes every month, I add RAG, so it reads the current text for each question. I only fine-tune when the output still drifts in style or format after good prompts and tests, because training is slow and makes facts hard to update.
The first thing I'd say is to try the cheapest fix before the expensive one. Prompting means better instructions and a few examples, and you can test it quickly. For tasks like summarising, translation and code generation it is often enough, and OpenAI's own guide starts there. I measure every change on a fixed set of test questions, so I know whether it helped.
If the model lacks facts, I add retrieval, which is RAG. Take a mid-size bank's support assistant. Its fee sheet changes every month, so a model trained on last month's version would quote old fees. With RAG, the system searches the current sheets for each question, pastes the matching passages into the prompt, and the model answers from them. The reply can show the sheet date it used.
I fine-tune only when the output still drifts after good prompts and tests, such as a format that breaks now and then or a tone that won't hold. Fine-tuning shapes how the model behaves, so it is poor at storing facts that change. It also needs good data, and OpenAI says it is winding down its fine-tuning platform for new users, so I check what is available first.
In short, I try prompting, add RAG for missing facts, and fine-tune for steady behaviour. The three can work together, and the test results decide.
What are prompting, RAG and fine-tuning, in plain words?
Prompting means writing better instructions and examples for a model you already have. RAG, short for retrieval-augmented generation, means finding the right passages in your own documents and pasting them into the prompt before the model answers. Fine-tuning means training the model on many examples of good answers, so its own internal settings (its weights) change.
Think of a new hire at a bank's call centre. Prompting is the briefing on day one. RAG is the fee sheet they look up before answering a customer. Fine-tuning is months of coaching until they answer in the house style without looking anything up. An AI team faces the same choice with a support assistant that must quote this month's fees and always use the same reply format.
Key words
- Prompt
- The instructions and examples sent to the model with each request.
- RAG
- Retrieval-augmented generation: fetch relevant text, then answer from it.
- Fine-tuning
- Training a model on examples, so its own settings change.
- Weights
- The numbers inside a model that training adjusts.
- Eval
- A fixed set of test questions with checked answers, used to score a change.
Which one fixes which problem?
Each fix changes a different thing. Prompting changes the request. RAG changes what the model reads. Fine-tuning changes the model itself. OpenAI's guide splits the problem the same way, into context and the model:
“Context optimization: You need to optimize for context when 1) the model lacks contextual knowledge because it wasn't in its training set, 2) its knowledge is out of date, or 3) it requires knowledge of proprietary information”
OpenAI, on context
“LLM optimization: You need to optimize the LLM when 1) the model is producing inconsistent results with incorrect formatting, 2) the tone or style of speech is not correct, or 3) the reasoning is not being followed consistently”
OpenAI, on the model
Which fix to try first
Wrong answer
Find out what kind of wrong
Three fixes, cheapest first
Prompting
Clearer rules and examples
RAG
Fetch current facts per question
Fine-tuning
Steadier style, fixed format
Checked by your evals
Keep only what scores higher
- 1Sort the failure first: missing facts, or behaviour that drifts.
- 2The fix that scores best on the same test set is the one that stays.
Missing or old facts point to RAG. Wrong formatting, a tone that slips, or reasoning that comes and goes point to the model. Anything clearer instructions can fix should be tried in the prompt first.
In what order should you try them?
- 1
Prompting first
Write a clear prompt and test it on a fixed set of real questions. OpenAI's guide calls prompt engineering typically the best place to start, and Google's Gemini tuning guide says the same order: prompting, then tuning if it is still needed.
- 2
Add RAG for missing facts
If the model lacks knowledge, or the knowledge is old or private, fetch it for each question. OpenAI's guide names those three cases: knowledge the model never saw, knowledge that is out of date, and proprietary knowledge.
- 3
Fine-tune for steady behaviour
Only when the output still drifts in format, tone or reasoning after good prompts and tests. Tuning then fixes the recurring errors that prompts could not hold.
Tip
Say the order out loud. Interviewers want to hear that you measure each step before you spend more on the next one.
How does RAG work for a bank's fee questions?
Here is a realistic case. A mid-size bank runs a support assistant that gets about 20,000 questions a month. Its fee sheets change at the start of every month, and some fees differ by card and by region. A model trained on last quarter's sheets would give confident, out-of-date answers, so the team uses RAG.
How RAG answers a fee question
Customer asks
Which fee applies to my card?
Search the fee sheets
Finds the current passages
Build the prompt
Question plus the passages found
Model writes the reply
Answers from the passages
Reply shows sheet date
Staff can check the source
- 1The customer's question becomes a search over the bank's sheets.
- 2The closest matching passages come back from the search.
- 3The passages go into the prompt, next to the question.
- 4The reply goes out with the sheet date it was built from.
The hard part is getting the right passage back. OpenAI's guide warns that you can supply the wrong context, or too much irrelevant context, and the model then answers badly. So the team builds an eval set of a few hundred real fee questions, with answers the fee team has checked, and scores retrieval and answers separately.
Small knowledge bases may need no RAG at all. Anthropic's post on contextual retrieval said that a knowledge base smaller than about 200,000 tokens (the units a model counts text in, about 500 pages here) can simply go in the prompt. A small, stable set of rules belongs in the prompt.
When is fine-tuning worth the cost?
Fine-tuning trains the model on examples of what good looks like. OpenAI describes supervised fine-tuning as a way to get a model that more reliably produces your desired style and content.
Data comes first. OpenAI suggests starting with 50 well-crafted demonstrations, and if 50 good examples make no difference, rethinking the task or prompt before adding more data. Google's Gemini tuning guide suggests a sizable labelled dataset, think 100 examples or more.
The payoff is a lower cost per call. Google's Gemini tuning guide notes that tuning can cut the cost of each request by removing the example answers pasted into the prompt (few-shot examples) and long instructions, so every call is shorter.
The limit is facts. A tuned model is poor at knowing what changed last month, and OpenAI's guide puts out-of-date knowledge under context, meaning the text the model reads for each question. That is where RAG lives.
Tip
Check availability before you plan a tuning project. OpenAI says it is winding down its fine-tuning platform: new users can't get in, and existing customers can create training jobs until December 15, 2026.
What does the interviewer want to hear?
A strong answer covers
- A plain split: prompts change the request, RAG changes what the model reads, tuning changes the model.
- The order: prompting first, then RAG for missing facts, then tuning for steady behaviour.
- Why facts go to retrieval: they change, and a tuned model has to be retrained to pick up each change.
- How you would measure each step on a fixed test set.
- The limits of tuning: data, time, cost and platform availability.
- That the tools combine: RAG for facts, tuning for format, with evals deciding.
Common traps
Trap"Fine-tune it on our documents so it knows them."
BetterTraining is a poor store for facts. Changing them means retraining, so put changing facts in retrieved text.
Trap"RAG makes the model smarter."
BetterRAG gives it the right text for each question. Tone and format are a job for prompts or tuning.
Trap"Always fine-tune for better quality."
BetterTry prompting and retrieval first. Tuning needs good data, time and money, and it may not be available to you.
Can you pick the right tool?
Spot the weak plan
A bank wants its assistant to stop quoting old fees. Which plan is wrong?
Quick check
An insurance claims bot quotes last year's policy limits. What is the best first fix?
Can you answer these from memory?
Flash cards · tap a card to flip it
What will they ask next?
- Q138RAG vs long context: which to use?12 min
- Q294How do you prepare a fine-tuning dataset?11 min
- Q306Fine-tuning for tone or format?11 min
- Q284What is LoRA?10 min
- Q308Fine-tuning cost vs inference savings?Coming soon
Learn it in depth
Last updated on 26 November 2026
Building an assistant that must answer from your own documents?
I design and build AI products and agents, the screens and the system behind them. Book a short call and say what you need.