Prompt engineering
Writing and testing clear requests for an AI tool. The aim is an answer that meets your task and can be checked.
Most bad answers come from a missing part: no material, or no rule for what to do when the answer is not there. Behind your prompt sits a hidden one from the app, the system instruction, which sets the ground rules.
The fuller definition
Prompt engineering is the practice of writing and refining instructions, examples, and context so a model produces more useful and more checkable output.
Go deeper
- Task
Define the output
- Context
Supply the right material
- Refine
Fix one specific failure
A simplified relationship, not a screenshot or a complete design.
A concrete example
Replacing review this with a task, a defined output format, and a rule for missing facts.
The distinction that matters
It improves the request. It does not verify the answer or change what data the model can access.
Related terms
Prompt
What you give a model to guide its reply. This may include a question, rules, and source text.
Prompting & contextContext engineering
Choosing what a model gets to work with. Give it the facts and rules it needs. Leave out clutter that may confuse the task.
Prompting & contextFew-shot prompting
Showing the model a few examples of what you want before asking it to do the same thing.
Where it is taught
Give AI a brief it can actually followSource and further reading
Anthropic · Context engineeringThe definition and example are written for this library. The link gives background, official documentation or legal authority as labelled. Legal scope depends on the jurisdiction and current text; product features depend on release and settings.