AI engineering glossary · Prompt context engineering

What is context engineering?

Context engineering: The craft of deciding what information goes into a model's input at each step: instructions, history, retrieved documents, tool results and examples, and in what order and amount. It goes beyond wording a single prompt and matters most for long-running agents.

Level: intermediateTopic: Prompt context engineering

Context engineering: an example

An assistant keeps the latest 5 messages, a summary of older ones, and the 3 most relevant policy passages for each turn.

Related terms

More Prompt context engineering terms

Where you learn it

Context engineering is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.