Artificial Intelligence

In-Context Learning

An LLM's ability to learn new tasks from examples or instructions provided within the prompt, without any weight updates or fine-tuning. The model adapts its behavior based on the context given.

Why It Matters

In-context learning is why LLMs are so versatile — you can teach them new tasks on the fly just by showing examples, making them instantly adaptable.

Example

Providing an LLM with 3 examples of English-to-Pirate translation in the prompt, and it immediately translates new sentences into pirate speak — no training required.

Think of it like...

Like a quick study who watches a few examples of a card trick and can immediately replicate it — they learn the pattern in real time from the demonstrations.

Related Terms