Prompt Engineering Tutorial menu

What Makes a Good Prompt

A good prompt tells the AI clearly what to do, for whom, with what information and in what form.

What is a Prompt?

A prompt is the text you give to an AI model: a question, an instruction, or a document with a request. The model reads your prompt and generates a reply. It cannot read your mind, so anything you leave out, it has to guess.

The Five Building Blocks

BlockQuestion it answersExample
TaskWhat should the AI do?"Write a leave application"
AudienceWho is it for?"for my school principal"
ContextWhat background does it need?"I was sick with fever for 2 days"
FormatWhat should the result look like?"formal letter, 3 short paragraphs"
LimitsWhat should it avoid or keep to?"under 120 words, no difficult words"

You do not need all five every time, but the more that matter, the better.

Weak vs Strong

Weak:

Example

text
Write an application.

Strong:

Example

text
Write a formal leave application to my school principal.
I was absent on 12 and 13 October because of a fever.
Keep it under 120 words, use simple English, and include
a place for my name, class and roll number at the end.

The weak prompt does not say what kind of application, who it is for, or why. The strong one leaves almost nothing to guess.

A Prompt Template

You can build prompts from the five blocks. Here is a small Python helper that does it:

Example

python
def make_prompt(task, audience, context, fmt, limits):
    return (f"{task} for {audience}.\n"
            f"Context: {context}\n"
            f"Format: {fmt}\n"
            f"Limits: {limits}")

print(make_prompt(
    "Explain what a database is",
    "first-year IT students",
    "they already know what a spreadsheet is",
    "3 bullet points and one example",
    "under 80 words",
))
Output
Explain what a database is for first-year IT students.
Context: they already know what a spreadsheet is
Format: 3 bullet points and one example
Limits: under 80 words

Apps that use AI often build prompts in code like this, filling in the details for each user.

Common Mistakes

  • Too vague: "Tell me about marketing." Marketing for whom? What part?
  • Too many tasks at once: ask for one main thing, or number the tasks clearly.
  • Hidden assumptions: the AI does not know your syllabus, your shop or your client unless you say so.
  • No format: you get a long essay when you wanted a table.
  • Accepting the first answer: prompting is a conversation. Ask for changes.

Improve by Following Up

You can refine an answer with short follow-ups:

Example

text
Make it shorter.
Use simpler words.
Add one example from a Karachi shop.
Turn this into a table with two columns.

Treat the AI like a smart new assistant on their first day: clever, but they know nothing about your situation until you explain it.

Positive Instructions Work Better

Say what you want, not only what you do not want. "Write in short, simple sentences" works better than "Don't be complicated."

Exercise

Exercise

Which prompt is the strongest?

Learn Prompt Engineering with a teacher

Join the AI & Prompt Engineering course at Workownix, online or in Orangi Town, Karachi, and get a certificate.

See the course Ask on WhatsApp