Definition
Context engineering is the practice of shaping what information an agent sees to optimize its output. This includes selecting relevant documents, filtering conversation history, prioritizing recent data, and structuring the input to maximize the agent's ability to produce accurate, useful results.
Example
When an agent handles a customer complaint, context engineering ensures it sees the customer's history, previous complaints, relevant policies, and the current issue, but not unrelated data from other customers or departments.
Why it matters
The quality of an agent's output is directly determined by the quality of its input. Context engineering is the skill of giving agents exactly what they need to succeed.