Context for Prompt Engineerings
Context is about deciding what goes into the model's limited window. Context engineering selects, orders and trims instructions, history, retrieved documents and tool results. Prompt caching lets a provider reuse an unchanged prompt prefix at lower cost and latency, so stable content should come first and changing content last.
Stage: Context Engineering · Part of the Prompt Engineering roadmap · Last reviewed 19 November 2026
What to learn in Context
- Decide which conversation history to keep, summarise or drop
- Place static instructions first to benefit from prompt caching
- Trim retrieved passages to the most relevant few
- Estimate cost from input and output token counts
- Recognise context rot when long prompts bury the important instruction
Context interview questions
How does prompt caching reduce cost?
When the start of a prompt is identical across requests, the provider can reuse its processed form instead of recomputing it, usually charging less for those cached tokens and responding faster. Put system instructions and fixed documents before variable user input.
Why can adding more context make answers worse?
Models can lose track of details in very long inputs, and irrelevant text competes with useful text for attention. A smaller, well-ordered set of relevant passages with the key instruction near the end often beats dumping everything in.
Where Context fits in the Prompt Engineering roadmap
Context belongs to the Context Engineering stage (beginner level), which takes about 9 hours. Beyond a single prompt.
Other units in this stage
Back to the full Prompt Engineering roadmap