Choose retrieval, fine-tuning or a better task definition
In this article (5 sections)
Retrieval, prompting and fine-tuning address different failure mechanisms. Choosing from tool popularity can make the system more expensive without repairing the task.
Diagnose three cases
The offline foundations lab records an authored decision table.
from foundation_cases import adaptation_choice_case
result = adaptation_choice_case()
assert result["retrieval_for_current_knowledge"] is True
assert result["fine_tuning_default"] is False
print(result["cases"])A missing current policy calls for retrieval. Ambiguous output fields call for a better task definition. A stable, labelled style transformation may justify considering fine-tuning after a prompt baseline fails. The table is a reasoning fixture, not proof that a technique will work on a live task.
Match method to evidence
Use task redesign when the requested outcome, labels, user action or acceptance criteria are unclear. No adaptation can rescue an undefined target.
Use retrieval when answers depend on current, private or source-citable information. Evaluate source ingestion, retrieval recall and answer support separately.
Use fine-tuning when you have sufficient rights-cleared examples of a stable input-output behaviour and a baseline shows a repeatable gap. It can improve style, format or task behaviour; it does not become a reliable database for frequently changing facts.
Prompting and structured output remain baselines across all three. Tool use may be appropriate when the answer requires calculation or an external operation rather than stored knowledge.
Write a decision record
Document failure taxonomy, available data, freshness, latency/cost constraints, baseline results and the experiment that would reject the choice. Include maintenance: retrieval requires source lifecycle controls; fine-tuning requires dataset/checkpoint provenance and reevaluation after model changes.
The Generative & Agentic AI course covers prompt, RAG and adaptation paths through explicit selection evidence rather than assuming every project needs LoRA.
Exercise
Classify 15 observed failures from one application. Assign task redesign, prompt/schema, retrieval, tool, fine-tuning or no automation. Select one method, state a cheaper baseline and define a fixed evaluation that can reject it.
Continue learning
This article is part of the LLM fundamentals and prompt design sequence. Use the neighbouring tasks when you need the prerequisite or the next application.
- Review the prerequisite or neighbouring task in Define a prompt versioning and review convention.
- Continue with Create a small labelled dataset for an LLM application.
Reference: Hugging Face PEFT documentation.
Pankit Kumar has 10 years in Data Science & AI, building and shipping production systems in regulated pharma and clinical environments. He is a freelance trainer at Boston Institute of Analytics, AnalytixLabs and Scaler, and has taught this material to thousands of working professionals.
This article is part of our Generative & Agentic AI programme — 3 months. Add practical GenAI, retrieval and agent-building skills to your existing toolkit.
Explore Generative & Agentic AI