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.
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
- Context stuffing
- Context truncation
- Contrastive chain-of-thought
- Conversation buffer memory
- Conversation history
- Delimiters
- Developer message
- Directional stimulus prompting
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.