AI Glossary / Prompting and human-AI interaction / Intermediate
Prompt-based learning
Definition
Prompt-based learning uses prompts to guide a pretrained model toward a task or desired behavior. In the everyday language-model sense used here, instructions, examples and context can change the model's responses without changing its learned weights. Research also uses the term more broadly for prompt-centered methods that may include training.
What it means
A model can be asked to summarize a paragraph, classify its tone or rewrite it for a different audience. The same model may respond differently because the prompt specifies a different task, even though the underlying parameters remain fixed.
The word learning can cause confusion. An improved answer after a clarification does not by itself prove a permanent change to the model. The clarification may simply remain in the current context and influence subsequent generation.
It is therefore useful to state the mechanism: in-context adaptation, learned soft prompts, model fine-tuning or a separate memory system. These approaches differ in persistence, data and computation requirements.
How it works
A task is expressed in a form the pretrained model can use, such as an instruction, a completion template or a small collection of demonstrations. The prompt combines this task description with the particular input to process.
In a fixed-model setup, inference conditions the output on that combined context. A classification prompt might restrict the response to specified labels; a rewriting prompt might demonstrate a tone and length. The application's evaluation determines whether the response actually follows those conventions.
More technical prompt-based methods can map language-model predictions to task labels or optimize prompt parameters from data. These extensions should be described explicitly. The original GPT-3 few-shot experiments are a primary example of task specification through textual demonstrations without task-specific gradient updates; they do not establish that every prompt works reliably.
Three practical examples
- A writer supplies a paragraph and asks for a simpler version for a non-specialist audience, then clarifies which technical terms must remain.
- A support analyst supplies a short label guide and examples so a model can classify incoming requests using the team's terminology.
- A researcher asks the same model to extract dates from a passage and, in a separate prompt, summarize the passage's main point.
Think of it this way
Think of giving a skilled assistant a temporary set of task instructions. The assistant can use existing capabilities in a new way without undergoing a new training course for each request.
The analogy should not imply that a model understands or retains instructions as a person would. A response can change because the current context changed, and that effect may disappear when the context is removed.
Worked example
Consider an original labeling task for fictional warehouse notes. The rule is: return "R" when a note explicitly says replenishment is required, "N" when it explicitly says replenishment is not required, and "U" when the note does not establish either conclusion.
The prompt includes two demonstrations:
"Replenishment is required before tomorrow." → R
"The shelf was inspected this morning." → U
For the new note, "Inspection complete; replenishment is not required", the intended response is N. The model must apply the stated rule to the new input rather than select only a label seen in the demonstrations.
Suppose a fixed-model evaluation contains thirty previously unused notes, ten for each label. With this prompt, the model correctly labels nine R cases, eight N cases and seven U cases. Total accuracy is 24/30 = 80%.
A revised prompt clarifies that inspection alone does not establish replenishment status. On the same development cases, it gets nine, eight and nine correct, giving 26/30, approximately 86.7%. This shows an observed prompt-level change on that collection, not a permanent model update or independent evidence of generalization.
Assess the revision on held-out cases. The counts and labels are invented.
Illustrative case study
Fictional case: Cedar Training creates an assistant for rewriting internal learning materials. The team provides audience descriptions, examples of acceptable simplification and a rule to preserve quoted technical definitions.
Reviewers find that a request for "simple language" sometimes removes an important qualification. They revise the prompt to require preservation of conditions and uncertainty, then test it on material not used to choose the wording.
The application records prompt versions without describing conversation corrections as retraining. This fictional case claims no measured educational benefit.
Common misconceptions and mistakes
- Learning necessarily means changing model weights: in-context adaptation can occur with fixed parameters.
- A correction in one conversation permanently fixes the model: persistence depends on a separate mechanism.
- Prompt-based methods require examples: zero-shot instructions are also commonly used.
- Good performance on familiar demonstrations proves transfer: demonstrations and evaluation cases serve different purposes.
- Prompt wording can supply missing evidence by itself: instructions cannot make an unavailable fact reliably present.
Business use
Prompt-based approaches can provide a relatively quick way to explore whether an existing model supports a business task. They can also reduce the need to build a separate task-specific model before the workflow is understood.
The trade-offs include sensitivity to wording, context limits and inconsistent handling of exceptions. Record the exact prompts and evaluate realistic cases. Distinguish development improvements from final test results, and compare with retrieval, deterministic rules or trained alternatives when appropriate. If persistent adaptation is required, specify whether it comes from saved context, a memory store or actual parameter training.
People also ask
How is this different from prompt engineering?
Prompt engineering is the activity of designing and testing prompts. Prompt-based learning describes the model-use or adaptation approach those prompts support.
Is it the same as in-context learning?
In everyday fixed-model use, the concepts strongly overlap. Broader research usage can include trained prompts and other methods.
Does the model remember a new label convention?
It may follow it while the convention remains in context. Behavior in a fresh session should not be assumed to retain it.
Check your understanding
A model gives a better answer after the user adds a clarification. Does that prove its weights changed?
Answer: No. The additional context can change generation while the parameters remain fixed. Evidence of a separate training operation would be needed to claim a weight update.
Related terms
- Prompt engineering
- Few-shot prompting
- Zero-shot prompting
- Soft prompt tuning
- Fine-tuning
- Context window
- In-context learning
- instruction following
- task adaptation
Learn next
Try one fixed model on a task using instructions alone and then instructions with demonstrations. Keep the evaluation inputs separate from the examples. Record which changes improve performance, and test the final prompt on fresh cases before treating the improvement as general.
More in Prompting and human-AI interaction
- Prompt chaining - Prompt chaining connects multiple model calls so that an earlier call's output becomes part of a later call's input.
- Prompt set - A prompt set is a collection of prompts used to evaluate a language model or an AI application.
- Prompt tuning - Prompt tuning is a parameter-efficient adaptation method that learns continuous prompt vectors while keeping the underlying pretrained model fixed.
- Role prompting - Role prompting asks a generative AI model to respond from a specified role or persona, such as a patient tutor, editor or interviewer.
- System prompt - A system prompt is an application-level instruction supplied to a language model to establish its role, task, behavior or response conventions.
- Tree-of-thought prompting - Tree-of-thought prompting organizes language-model problem solving as a search over alternative intermediate steps.
Sources
Google Machine Learning Glossary, prompt-based learning: https://developers.google.com/machine-learning/glossary
Brown and colleagues, Language Models are Few-Shot Learners, 2020, for fixed-parameter demonstration-based inference: https://arxiv.org/abs/2005.14165
Lester and colleagues, The Power of Scale for Parameter-Efficient Prompt Tuning, 2021, for the distinct trained-soft-prompt mechanism: https://aclanthology.org/2021.emnlp-main.243/
The warehouse labels, scores and Cedar Training case are original hypothetical illustrations.
Previous: Prompt Next: Prompt chaining