Prompt Engineering: Structure, Context and Constraints

You can build a prompt with role, task, format and constraints.

Why this lesson matters

You now know that a good prompt is more than a question. But how do you build such a prompt? Is there a structure that always works?

Yes. There's a framework you can use as a blueprint for almost any prompt. Whether you want an email, a report, an analysis or a presentation, the framework is the same. In this lesson you'll learn it by heart.

The Prompt Framework

Every strong prompt contains up to five building blocks:

Building blockWhat it doesExample
PersonaGives the AI a role and expertise"You're a senior financial analyst"
TaskWhat exactly the AI has to do"Write a quarterly report"
ContextBackground and relevant details"For an SME with €5M revenue"
FormatWhat the result should look like"Use a table with 4 columns"
ConstraintsLimits and conditions"Max 500 words, no jargon"
Going deeper

You don't always need all five building blocks. For a simple question, Task + Context is often enough. But the more complex the assignment, the more building blocks you need.

Building block 1: Persona

By giving the AI a role, you steer the tone, the knowledge level and the angle of the answer.

Compare:

text
Explain inflation.

vs.

text
You're an economics lecturer at a university of applied sciences. Explain inflation to first-year students who have no background in economics.

The first answer turns into a Wikipedia article. The second turns into an understandable explanation at the right level.

Good personas:

Keep reading

Leave your name and email address and you can read the rest

You get the whole lesson right away, and every other lesson stays open after that. No password, no confirmation email.

Your address stays with us. No selling to third parties, and you unsubscribe in one click.