One-shot Prompting – Prompting With a Single Example

One-shot Prompting

A technique where the model is given one example of how to do the task. This method lets the model adapt quickly to a new type of task based on a single demonstration.

AdvantagesDrawbacks
Fast adaptation to new tasksCan be less accurate than methods with more examples
Minimal data requirementsDepends on the quality and representativeness of the single example
Flexible across different types of tasksMay not suit complex or many-sided tasks

An example of One-shot Prompting:

Rephrase the following sentence while keeping its meaning.
Example:

Original: 'The cat was sitting on the windowsill.'
Rephrased: 'On the edge of the window a cat had settled.'

Now rephrase this sentence:
Original: 'The students were preparing hard for the exam.'
Rephrased:

Try it in GPTunneL