# Types of prompts: a prompt engineering guide with examples

> The main types of prompts for ChatGPT and other AIs (zero-shot, few-shot, role, chain of thought, structured instructions and system prompt), with examples and a prompt engineering checklist.

- **HTML version:** https://tolky.to/en/blog/types-of-prompts
- **Author:** [Marlos Carmo](https://tolky.to/en/author/marlos), Co-founder of Tolky
- **Published:** November 23, 2026
- **Reviewed:** November 23, 2026
- **Language:** en

## Summary

The main **types of prompts** are zero-shot (instruction only), few-shot (instruction with examples), role prompt, chain of thought, structured instructions and system prompt, which sets the fixed behavior of an AI agent. **Prompt engineering** is choosing and combining these types to get correct answers, in the right format, with clear limits.

Two people ask ChatGPT for the same thing and get answers of very different quality. The difference is almost never the model: it's the request. A vague prompt returns generic text; a prompt with context, an example and a format returns something you can actually use.

This guide covers the main types of prompts, when to use each one, ready-to-adapt examples and how the same thinking applies to setting up an AI agent that serves customers. It works for ChatGPT, Gemini, Claude and any language model.

*Updated November 2026.*

## What is a prompt and what is prompt engineering?

**A prompt is the natural language instruction you give a language model to get a response, and prompt engineering is the practice of writing, testing and refining those instructions so the response comes out correct, useful and in the expected format.**

A prompt can be a one-line question or a multi-page document with rules, examples and data. The model can't read your mind: it responds to what is written, within the amount of text it can consider at once, its [context window](https://tolky.to/en/glossary/context-window).

The short definitions are in the glossary, under [prompt](https://tolky.to/en/glossary/prompt) and [prompt engineering](https://tolky.to/en/glossary/prompt-engineering). For the technical basis of these models, see the entry for [LLM](https://tolky.to/en/glossary/llm).

## What are the types of prompts?

**The six most common types of prompts are zero-shot, few-shot, role prompt, chain of thought, structured instructions and system prompt.** They aren't mutually exclusive: a good prompt usually combines two or three.

| Type | What it is | When to use it | Limit |
| :--- | :--- | :--- | :--- |
| Zero-shot | The instruction only, no examples | Common, clear tasks | Format and tone vary |
| Few-shot | Instruction with a few input and output examples | When format or style matters | Bad examples teach the wrong thing |
| Role prompt | Defines who the model should be | Adjusting vocabulary, technical level and tone | A role doesn't add knowledge the model lacks |
| Chain of thought | Asks the model to reason in steps | Calculations, logic, decisions with several conditions | Longer, slower answers |
| Structured instructions | Sections, delimiters and a defined output format | Repeated tasks, integration with systems | Takes more time to write |
| System prompt | Fixed rules that apply to the whole conversation | AI agents and custom assistants | Needs testing and ongoing review |

## Zero-shot prompt: the instruction only

**A zero-shot prompt describes the task without giving any example, relying on what the model has already learned.** It is the most common type and works well for clear requests.

Illustrative example:

```text
Summarize the complaint below in one sentence and say whether the customer is asking for a refund, an exchange or something else.

Complaint: "I bought the coffee maker on the 3rd, it arrived with a broken lid and I want another one just like it."
```

To improve a zero-shot prompt, be specific: state the length, the audience and the format. "Summarize" is vague; "summarize in one sentence for a supervisor" is clear.

## Few-shot prompt: learning from examples

**A few-shot prompt shows a few input and output examples before the task, so the model imitates the pattern.** The name comes from the paper "Language Models are Few-Shot Learners", by Tom Brown and coauthors, published in May 2020, which showed models learning tasks from a few examples in the prompt itself ([arXiv](https://arxiv.org/abs/2005.14165), checked on November 23, 2026).

Illustrative example, for classifying messages:

```text
Classify the intent of the message.

Message: "I want to cancel my plan" -> Intent: cancellation
Message: "How long does delivery to Recife take?" -> Intent: delivery
Message: "I was charged twice" -> Intent: billing

Message: "My order still hasn't arrived" -> Intent:
```

Use varied, correct examples. If every example is short, the answers will be short; if one example is wrong, the model repeats the mistake.

## Role prompt: who the model should be

**A role prompt gives the model a persona or function, such as "you are a support analyst at an internet provider", to adjust vocabulary, technical level and tone.**

Illustrative example:

```text
You are a support analyst at an internet provider. Explain to a customer with no technical knowledge how to restart the router, in no more than five short steps.
```

The role changes how the model answers, not what it knows. "You are a lawyer" doesn't turn the answer into a legal opinion. For facts about your company, the model has to receive the content, as the guide on how to [train an AI agent with a knowledge base](https://tolky.to/en/blog/train-ai-agent-knowledge-base) shows.

## Chain of thought: thinking in steps

**A chain-of-thought prompt asks the model to work through the problem in steps before giving the final answer, which improves results on logic, calculation and decisions with several conditions.**

The technique was described in a paper by Jason Wei and coauthors published in January 2022 ([arXiv](https://arxiv.org/abs/2201.11903)). Months later, Takeshi Kojima and coauthors showed that simply adding "Let's think step by step" already helped, with no examples ([arXiv](https://arxiv.org/abs/2205.11916), both checked on November 23, 2026).

Illustrative example:

```text
A customer bought on November 2 and requested an exchange on November 20. The policy allows exchanges up to 30 days after purchase, except for sale items, which have 7 days. The product was on sale.
Analyze the conditions one by one and then say whether the exchange is allowed.
```

Newer models, called reasoning models, already do this step internally. With them, asking to "think step by step" changes little; it pays more to describe the conditions well and ask for the conclusion with its justification.

## Structured instructions: sections, delimiters and format

**Structured instructions organize the prompt into blocks (context, task, rules, output format) and separate data from instructions with delimiters, so the model doesn't confuse what is an order with what is content.**

Illustrative example:

```text
## Context
We are a furniture store delivering in São Paulo and Campinas.

## Task
Read the customer's message between the <message> tags and reply.

## Rules
- Don't promise a delivery time; say the time shows up at checkout.
- If the customer asks for a discount, say you will bring in a salesperson.

## Format
Reply in up to 3 sentences, no emojis.

<message>
Do you deliver to Jundiaí? And do you give a discount for paying upfront?
</message>
```

Separating data with delimiters such as `<message>` also reduces the risk of [prompt injection](https://tolky.to/en/glossary/prompt-injection), when outside text tries to give the model orders. For tasks connected to systems, ask for the output in JSON or as a list with fixed fields.

## System prompt: the foundation of an AI agent

**The system prompt is the set of fixed instructions that defines who the agent is, what it does, what it never does and when it hands off to a person, and it applies to every conversation, before any user message.** It is the type of prompt that turns a generic model into an [AI agent](https://tolky.to/en/blog/what-is-an-ai-agent-complete-guide).

A customer service system prompt usually has six blocks:

1. **Identity.** Name, company and the fact that it is an AI assistant.
2. **Mission.** The agent's goal: support, sales, scheduling.
3. **Scope.** What it handles and what it declines.
4. **Sources.** Answer only from the knowledge base and say when it doesn't know.
5. **Tone.** Formal or friendly, short sentences, no jargon.
6. **Handoff.** When to bring in a person and what to tell the customer.

Short illustrative example:

```text
You are the AI assistant for Example Clinic. Your mission is to book, reschedule and cancel appointments and answer questions about health plans and the address.
Answer only from the clinic's information. If you don't know, say you will check and transfer to the front desk.
Never give medical advice or interpret test results: in those cases, transfer to the front desk.
Be friendly and objective, in short sentences. Introduce yourself as an AI assistant in the first message.
```

Ready-made templates are on the [AI agent prompts](https://tolky.to/en/resources/ai-agent-prompts) page. To build a personal assistant with fixed instructions, see how to [create a custom GPT in ChatGPT](https://tolky.to/en/blog/custom-gpts-chatgpt-migrate-to-customer-service-agent) or a [Gem in Gemini](https://tolky.to/en/blog/gemini-gems-and-skills-migrate-to-customer-service-agent).

## How to write a good prompt: checklist

**A good prompt says who the model is, what the task is, what information to work with, what rules to follow and what format to answer in.** If one of these parts is missing, the model fills the gap with assumptions.

| Element | Question it answers | Short example (illustrative) |
| :--- | :--- | :--- |
| Role | Who should the model be? | "You are a support analyst" |
| Task | What exactly should it do? | "Classify the intent of the message" |
| Context | What information should it use? | "Exchange policy: 30 days" |
| Examples | What does a good answer look like? | Two input and output pairs |
| Rules | What should it never do? | "Don't promise a delivery time" |
| Format | How should it deliver? | "Up to 3 sentences" or "JSON with fields X and Y" |

After writing, test with hard cases: ambiguous requests, out-of-scope questions and attempts to make the model break the rule. Adjust one element at a time so you know what changed the result.

## Common mistakes when writing prompts

**The most common mistakes are asking vaguely, mixing several tasks in one request and trusting that the model knows facts about your company.** All of them lead to generic or made-up answers.

- **Too vague.** "Improve this text" without saying for whom and with what goal.
- **Everything at once.** Summarize, translate and classify in the same request. Split it into steps.
- **No source.** Asking about company prices or policy without providing the document leads to [hallucination](https://tolky.to/en/glossary/ai-hallucination).
- **Contradictory rules.** "Be brief" and "explain everything in detail" in the same prompt.
- **Never testing.** An agent prompt that was never tested with hard cases will fail with the customer.

## Where Tolky fits in

**In Tolky, each AI agent's system prompt is built on the Identity screen, with mission, context, personality and tone, and completed by governance blocks, a knowledge base and tests before it goes live.** You write in natural language; the platform organizes it.

- **Identity and mission.** Who the agent is, why it exists and which mission it works on (support, sales and relationship, engagement, among others).
- **Improve with AI.** A button rewrites the identity text with a clearer structure.
- **Governance.** Scope, refusal policies and the uncertainty rule, so the agent doesn't make things up.
- **Knowledge base.** The company's files, links and texts, so answers come from your sources.
- **Simulations.** Personas and scenarios with success criteria, run in batches before publishing.

![Real screenshot of the Tolky Identity screen (Portuguese interface), in Simplified mode, with the agent identity and role field filled in with the agent's instructions, the Sales and Commercial Relationship mission, the welcome message and the behavior chart](https://tolky.to/screenshots/identidade.png)

**What Tolky doesn't do:** it isn't a prompt editor for personal use and doesn't replace ChatGPT in your daily work. It is a platform for agents that serve customers on channels such as WhatsApp, website and voice, with a CRM and people in the loop. To use AI responsibly, see also [ethics in artificial intelligence](https://tolky.to/en/blog/ethics-in-artificial-intelligence).

## Frequently asked questions

### What are the main types of ChatGPT prompts?

The most common are zero-shot, few-shot, role prompt, chain of thought, structured instructions and system prompt. They apply to ChatGPT and to other models, such as Gemini and Claude, and are usually combined.

### What is the difference between zero-shot and few-shot prompts?

In zero-shot you only describe the task. In few-shot you first show a few input and output examples, and the model imitates the pattern. Use few-shot when the format or style of the answer matters.

### What is a system prompt?

It is the set of fixed instructions that applies to the whole conversation: who the assistant is, what it does, what it doesn't do and when it hands off to a person. It is the foundation of any AI agent and of custom GPTs.

### Is prompt engineering still necessary with newer models?

Yes, though in a different way. Newer models understand simple requests better and reason on their own, but they still need context, rules and format. In customer service agents, the system prompt and testing remain essential.

### How do you keep AI from making up answers?

Provide the information in the prompt or in a knowledge base, ask the model to answer only from it and say what to do when it doesn't know, such as transferring to a person. Test with out-of-scope questions.

### Is there a perfect prompt?

No. A good prompt is written, tested with hard cases and refined little by little. What works in one model may need adjusting in another.

---

## Conclusion

Types of prompts are tools, not formulas: zero-shot for simple tasks, few-shot for format, role for tone, chain of thought for logic, structure for repeatable work and the system prompt for the agent that talks with customers. Combine them, test and refine.

[See AI agent prompt templates](https://tolky.to/en/resources/ai-agent-prompts), [explore WhatsApp Service](https://tolky.to/en/solutions/whatsapp-customer-service), [see the plans](https://tolky.to/en/pricing) or [talk to the team →](https://tolky.to/en/contact). Let's talk?

---

This is the Markdown version of the page. The full version, with images and navigation, is at https://tolky.to/en/blog/types-of-prompts

Tolky: https://tolky.to
