What Is a Prompt?
A prompt is everything you send to ChatGPT before it generates a response. That includes your question or instruction, any background context you provide, examples you include, and any constraints you specify about the format or style of the answer.
The word "engineering" in "prompt engineering" might sound overly technical. A better framing: prompting is a communication skill. Just as a well-worded email gets a faster, more useful reply than a vague one, a well-constructed prompt gets a faster, more useful response from ChatGPT.
The remarkable thing is that the gap between a weak prompt and a strong prompt is enormous — often the difference between a response you discard immediately and one you use almost verbatim. This chapter gives you a reliable framework for closing that gap.
The Anatomy of a Good Prompt
Strong prompts typically have five components. Not every prompt needs all five, but knowing them lets you diagnose why a prompt underperforms and fix it precisely.
1. Role
Tell ChatGPT what persona or expertise to adopt. This primes the model to draw on the vocabulary, reasoning patterns, and conventions appropriate to that role.
"You are a senior tax consultant with 15 years of experience advising
small businesses in India on GST compliance."
Without a role, ChatGPT answers as a generic assistant. With a role, it frames its response through the lens of a specific kind of expert.
2. Context
Provide the background the model needs to give you a relevant answer. Think of this as briefing a colleague who just joined the project. What do they need to know to be immediately useful?
"My client runs a small Kirana store in Jaipur with a monthly turnover
of approximately ₹8 lakhs. He currently files under the Composition
Scheme but is considering switching to regular GST registration."
Context is the most commonly omitted component. When a response feels generic or off-target, missing context is almost always the reason.
3. Task
State what you actually want done — the specific action or deliverable. Be precise. "Help me with GST" is a task statement. "List the pros and cons of switching from the Composition Scheme to regular GST registration, specific to a retailer with ₹8 lakh monthly turnover" is a task statement.
4. Format
Specify how you want the output structured. If you do not specify, ChatGPT will choose a format — and it may choose wrong. Common format instructions:
- "Respond in a numbered list"
- "Use a comparison table with columns for Composition Scheme and Regular GST"
- "Write this as a 200-word paragraph suitable for a WhatsApp message"
- "Structure the output with headings: Pros, Cons, and My Recommendation"
5. Constraints
Add guardrails that prevent the response from going in directions you do not want.
- "Do not discuss IGST or export-related rules — focus only on domestic retail."
- "Keep the response under 300 words."
- "Avoid legal jargon — this needs to be understood by someone with no accounting background."
- "Do not recommend specific software products."
Putting It Together: Before and After
Seeing the framework in practice is more instructive than any abstract description. Here are three before-and-after pairs.
Example 1: Email Drafting
Weak prompt:
Write an email about late payment.
What you get: A generic, overly formal email that could be from any industry, addressed to no one in particular.
Strong prompt:
Role: You are a professional accounts manager at a mid-size IT services firm.
Context: Our client, Rajiv Enterprises (a manufacturing company in Pune),
has an outstanding invoice of ₹2,35,000 for software development services
delivered in March 2026. Payment was due on 30 April. Today is 2 June.
This is the first follow-up. Our relationship with this client is good and
we want to preserve it.
Task: Draft a polite but firm payment reminder email.
Format: Professional email with subject line, body, and sign-off.
Constraints: Keep it under 150 words. Do not threaten legal action.
Maintain a warm, relationship-preserving tone.
What you get: A ready-to-send email, appropriately calibrated for the relationship and the amount at stake.
Example 2: Learning a Concept
Weak prompt:
Explain machine learning.
Strong prompt:
Context: I am a 3rd-year BCom student at a Bangalore university.
I understand basic statistics (mean, standard deviation, correlation)
but have no programming background.
Task: Explain what machine learning is and how it differs from
traditional programming, using an analogy relevant to everyday Indian life.
Format: Three short paragraphs — no bullet points, no jargon.
Constraints: Do not mention Python, R, or any specific algorithm by name.
Example 3: Content Creation
Weak prompt:
Write a product description for earphones.
Strong prompt:
Role: You are a conversion-focused copywriter for Indian e-commerce.
Context: The product is a pair of wired earphones priced at ₹599,
targeted at college students and budget-conscious buyers on Flipkart.
Key features: 12mm driver, in-line mic, tangle-free flat cable, 3.5mm jack.
Competitor products in this range sell primarily on value-for-money.
Task: Write a product description that leads with a relatable pain point,
highlights the three most important features as benefits (not specs),
and ends with a call to action.
Format: 100-120 words, no bullet points, conversational tone.
Constraints: Do not make claims about "studio-quality" or "audiophile"
sound — keep expectations realistic for the price point.
Zero-Shot vs. Few-Shot Prompting
Zero-Shot Prompting
Zero-shot prompting means giving the model a task without any examples. You rely entirely on its pre-trained knowledge and your instructions. Most everyday prompts are zero-shot.
Task: Classify the following customer review as Positive, Negative, or Neutral.
Review: "The delivery took 8 days instead of 2. The product itself is fine
but I'll think twice before ordering from this seller again."
Zero-shot works well for tasks the model has seen many variations of during training — sentiment analysis, translation, summarisation, coding, and most writing tasks.
Few-Shot Prompting
Few-shot prompting means including one or more worked examples before your actual task. The examples teach the model the exact pattern, format, or style you want, without relying solely on its pre-trained defaults.
Classify each customer review as Positive, Negative, or Neutral.
Examples:
Review: "Excellent quality, fast delivery. Will buy again!"
Classification: Positive
Review: "Wrong size sent. Return process was a nightmare."
Classification: Negative
Review: "Product is okay. Nothing special."
Classification: Neutral
Now classify this review:
Review: "Zomato delivered the wrong order and the support team
took 40 minutes to respond. Got a refund but very frustrating."
Classification:
When to Use Each
| Situation | Recommended Approach |
|---|---|
| Common, well-understood tasks | Zero-shot |
| Unusual output format the model might not default to | Few-shot (1-2 examples) |
| Strict classification with specific categories | Few-shot |
| Domain-specific tone or style (e.g., legal language, brand voice) | Few-shot |
| Tasks where consistency across many inputs matters | Few-shot |
A good rule of thumb: start zero-shot. If the output misses the format or style you need, add one or two examples — you rarely need more than three.
Understanding System and User Roles (Conceptual)
When you use the ChatGPT web interface, every message you send is a "user" message. But the model also supports a "system" role — instructions that sit above the conversation and shape every response the model gives.
In the web interface, Custom Instructions (Settings → Personalization) function as a lightweight system prompt. When you access ChatGPT through the API, you explicitly set a system message.
Conceptually:
- System role: Sets the operating context, persona, and rules for the entire conversation. Example: "You are a customer service agent for Meritshot. Only answer questions about our courses and pricing. Politely redirect any off-topic questions."
- User role: Your actual messages and requests within that context.
Understanding this separation matters because it explains why Custom Instructions are so powerful — they effectively give you a persistent system prompt without writing code.
The Most Common Beginner Mistakes
Mistake 1: Being Too Vague
"Tell me about marketing" could prompt a textbook chapter, a one-liner, a history of advertising, or a list of digital tools. It will not give you what you actually want because you have not told the model what that is.
Fix: Add task, context, and format. "Give me five low-budget digital marketing ideas for a first-generation entrepreneur selling handmade candles on Instagram, targeting customers in Tier-2 Indian cities."
Mistake 2: Asking Multiple Unrelated Things in One Prompt
Packing five distinct tasks into one message almost always produces a response that handles each one shallowly.
Fix: One focused prompt at a time. After you get a response, follow up with the next task. Conversational chaining produces better results than mega-prompts.
Mistake 3: Accepting the First Response Without Iterating
Many users treat ChatGPT like a search engine — one query, one answer. But ChatGPT is a conversation. If the first response is 80% right, tell it what the other 20% missed.
Fix: Use follow-up messages like:
- "This is good, but make it shorter — I need it under 100 words."
- "The tone is too formal. Rewrite it in a more casual, friendly voice."
- "You gave general advice. I need it specifically about the Indian GST system, not generic international tax advice."
Mistake 4: Not Specifying the Audience
The model has no idea whether your output is for a PhD researcher, a Class 6 student, or a non-English-speaking farmer unless you tell it. Pitch matters enormously.
Fix: Add "Explain this to someone who..." or "Write this for an audience of..." to your prompt.
Mistake 5: Forgetting Constraints on Length and Format
Without explicit guidance, ChatGPT tends toward medium-length prose responses. If you need a table, a JSON object, a numbered list, or a 50-word summary, you must ask for it.
Fix: Include explicit format and length instructions in every prompt that has a specific output requirement.
Mistake 6: Treating Output as Final Without Review
ChatGPT's responses are starting points, not finished products. Factual claims should be verified. Tone and style should be checked against your brand voice. Specific numbers (prices, statistics, dates) should be confirmed against primary sources.
Common Pitfalls
Writing prompts in a single rushed line. Spending 60 seconds structuring your prompt using the role-context-task-format-constraints framework will save you three rounds of back-and-forth iteration and produce a better final output. The investment pays off immediately.
Using prompt frameworks mechanically without thinking. Not every prompt needs all five components. A casual factual question — "What is the capital of Karnataka?" — needs no role, context, format, or constraints. Apply the framework where it adds value, not as a ritual.
Confusing few-shot examples with training. When you include examples in a prompt, you are not teaching the model permanently. The examples exist only within that conversation's context window. The next conversation starts fresh.
Assuming longer prompts are always better. Adding irrelevant context wastes tokens and can actually confuse the model by introducing conflicting signals. Include only context that is genuinely necessary for the task.
Practice Exercises
-
Take any prompt you have used in the past that gave a mediocre response. Rewrite it using the role-context-task-format-constraints framework. Compare the two outputs. Document which component made the biggest difference.
-
Write a zero-shot prompt asking ChatGPT to classify five Zomato customer reviews as Positive, Negative, or Neutral. Then rewrite the same request as a few-shot prompt with two worked examples. Compare the consistency and formatting of the outputs.
-
Deliberately write a one-sentence vague prompt and note the response. Then iteratively add context, format instructions, and constraints across three follow-up messages until the output is exactly what you would want. Observe how the response improves with each iteration.
-
Write a prompt asking ChatGPT to explain how a home loan EMI is calculated. First write it for a first-time buyer with no finance background. Then write the same prompt for a chartered accountant. Compare the vocabulary and depth of the two responses.
-
Create a few-shot prompt with three examples and feed it 10 different inputs. Notice any cases where the model breaks the pattern established by your examples. This builds intuition about the limits of few-shot prompting.
Summary
- A prompt is everything you send to ChatGPT before it responds — not just a question, but a communication that shapes the entire output.
- The five components of a strong prompt are role (what persona the model adopts), context (background the model needs), task (what you want done), format (how the output should be structured), and constraints (what to avoid).
- Zero-shot prompting asks the model to complete a task without examples; few-shot prompting includes one to three worked examples to demonstrate the exact pattern or style required.
- System and user roles separate standing operating context from individual messages; Custom Instructions in the ChatGPT interface serve as a lightweight system prompt for every conversation.
- The most common beginner mistakes are being too vague, asking multiple unrelated things at once, not iterating on the first response, forgetting to specify the audience, and treating ChatGPT output as final without review.
- Good prompting is a communication skill, not a technical one — and like all communication skills, it improves rapidly with deliberate practice.