Case & CodeA FIELD GUIDE TO AI
Start learning
Beginner

Prompt engineering

In plain words

Writing and testing clear requests for an AI tool. The aim is an answer that meets your task and can be checked.

A prompt has three parts
1. Instructions“List every date in this letter. If a date is conditional, say so.”
2. MaterialThe letter itself, pasted or attached.
3. Rules for problems“If you cannot find something, say ‘not found’ instead of guessing.”

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

How it fits together
  1. Task

    Define the output

  2. Context

    Supply the right material

  3. 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

Where it is taught

Give AI a brief it can actually follow

Source and further reading

Anthropic · Context engineering

The 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.

Lessons, terms, practical guides and sources ESC