# Your agent's prompt

> Edit what your agent says in its Prompt tab: instructions by sections, the first message, variables, styles, drafts, publishing and versions.

Source: https://docs.whatsetter.com/dashboard/prompt/

The **Prompt** tab of an agent holds everything it says: the first message it
writes, how it leads the conversation and its follow-ups. The Prompts page of
the old menu is gone: each agent now carries its own prompt.

## Open an agent's prompt

Open **Agents**, click your agent, then the **Prompt** tab. The top of the tab
shows the agent's messages in the order a lead meets them:

| Step | When it is used |
|---|---|
| **First message** | To every new lead the agent writes to first. |
| **Conversation** | As soon as the lead replies. These are the agent's instructions. |
| **Follow-ups** | When a lead stays silent. See [Automatic follow-ups](/dashboard/follow-ups/). |

The tab opens on **Conversation**. Click a step to edit its text. On the right
of the steps, a badge says whether the text on screen is live, and **Publish**
puts it live. A dot on a step means it holds unsaved changes.

This tab replaces the Prompts page and the prompt editor of the old menu. It
requires the **Edit agents and their prompts** permission. A group agent has
two texts instead, **In the group** and **In private**: see
[WhatsApp groups](/dashboard/groups/).

## Edit the agent's instructions

Open **Agents**, click your agent, then **Prompt**, and stay on the
**Conversation** step. The instructions read like a page: sections, each with
a title and its text. The usual sections also carry a line that says what
they are for.

Click in a text and write. What you read is what the agent reads, titles
included.

When the creation window writes the instructions, they have nine sections:
the agent's identity, its goal, how it opens, how it answers or builds on what
the lead says, the path of the conversation, facts and knowledge, style and
voice, objections and requests for a human, and its hard rules. The titles are
part of the text and you can rename them.

That text tells the agent to take facts such as prices, features and links
from its knowledge: see [Knowledge bases](/dashboard/knowledge-base/).

Your changes stay a draft until you click **Publish**.

## Rename, move, turn off or delete a section

Open **Agents**, click your agent, then **Prompt**. Each section has its own
controls:

- Click its title to rename it, and its icon to change it.
- Open the menu with three dots on its right for **Rename**, **Change icon**, **Move up**, **Move down**, **Turn off** and **Delete**.
- Above the text, the button that counts the sections lists them. Click one to jump to it, drag one to change the order.

**Turn off** keeps the text, but the agent skips the section while it is off.
The section then shows **Off**, and **Turn on** brings it back. In the first
message, a section cannot be turned off, only deleted.

**Delete** removes the section and its text from the draft. A window asks you
to confirm when the section holds text.

## Add a section

Open **Agents**, click your agent, then **Prompt**. At the bottom of the text,
click **Add a section**.

- **Recommended sections** lists the base sections your text no longer has. Picking one adds it back with its default text.
- **New section…** creates your own: give it a name and an icon, click **Add**, then write its text.

On the **First message** step, the second choice is
**Add a custom instruction**: a **Title** and an **Instruction**, or an
example to start from. The first message accepts up to 5 custom instructions.

A new section is part of the draft: click **Publish** to put it live.

## Change the first message

Open **Agents**, click your agent, then **Prompt**, and click the
**First message** step.

The first message is not a fixed text. Your agent writes a different message
for every new lead, and this step holds the brief it follows: who is writing
and why, the tone, the one question that opens the exchange, the format and
its limits, and examples to imitate.

1. Edit the sections like any other text.
2. Insert a variable where the message should use the lead's first name or a column of your list.
3. Click **Publish**. The first message is published on its own, apart from the conversation.

To read what the agent would send, generate a first message in the **Test**
tab: see [Test your agent](/dashboard/playground/). To compare two first
messages on real leads, see [A/B variants](/dashboard/ab-variants/).

When a lead comes from a form, the wait before the first message is set in
**Settings**, under **Sending**: **First message delay**, 3 minutes at least.

## Insert a variable

A variable is a value your agent fills in by itself. In the text it shows as a
chip that carries its name.

1. Open **Agents**, click your agent, then **Prompt**.
2. Click in the text where the value should go.
3. Type `/` or `{`, or click **Variable** above the text.
4. Pick the variable. Its chip appears where you write.

The list groups the variables in three families: **The prospect**, filled in
for each lead when the message goes out, **You and your offer**, the same for
everyone, and **The goal**, where the agent takes the conversation. A search
field finds a variable by its name or its value.

On the **Follow-ups** step, four variables are offered: the lead's first name,
the agent's name, your company and the language.

A variable that is not filled in shows **To fill in** in the list: give it a
value before you publish.

## The variables you can use

In the **Prompt** tab, each variable is a chip. The second column is how it is
written in the source code of the text.

| Chip | In the source | What the agent writes |
|---|---|---|
| **Lead’s first name** | `{{first_name}}` | The first name of each lead. |
| **Agent name** | `{{agent_name}}` | The agent's first name. |
| **Your company** | `{{company_name}}` | The name of your company. |
| **Your first name** | `{{owner_first_name}}` | Your first name, the person the lead is handed to. |
| **Your offer** | `{{offer_description}}` | The short description of your offer. |
| **Your promise** | `{{value_proposition}}` | Your key benefit. |
| **Your industry** | `{{business_focus}}` | Your industry. |
| **Top pain** | `{{top_pain}}` | The first problem of your audience. |
| **Language** | `{{language}}` | The agent's language. |
| **Your style** | `{{voice_persona}}` | The style chosen for the agent. |
| **Booking link** | `{{goal_link}}` | The link the agent sends. |
| **Target action** | `{{goal_action_noun}}` | What the agent steers toward, for example the call. |

## Change the value of a variable

Open **Agents**, click your agent, then **Prompt**. Click a chip in the text,
or click **Variable** above the text, then the pencil on a line.

- Type the new **Value** and click **Save**. Wherever the chip appears, the agent writes this value.
- **Agent name** and **Booking link** are set in the agent's **Settings**: the window shows the value and the button **Edit in Settings**.
- **Lead’s first name** has nothing to fill in: the agent uses the first name of each lead when the message goes out.
- **Your style** opens the window **Choose your agent’s style** instead.

If the text is already published, publish it again so the new value goes
live. The window reminds you: "Already published? Publish again so the new
value goes live."

## Use a column of your list in the first message

Every column you kept as a custom variable when importing a list becomes a
variable of the first message. In the source it is written `{{lead:column}}`,
for example `{{lead:company}}`.

Open **Agents**, click your agent, then **Prompt** and the **First message**
step. Click **Variable**: the family **The prospect** lists your columns, each
with an example taken from your list when there is one. Click one to insert it.

- These variables work in the first message only. On **Conversation**, the same family shows a line such as "3 variables from your lists · first message only".
- Each lead gets the value of its own row when the message goes out.
- Without any list column yet, the family offers **Import a list**.

See [Lists & import](/dashboard/lists/).

## Ask Setty to change a text

Setty is the writing assistant of the **Prompt** tab. It sits in a column on
the right of the text. On a narrow screen, the **Setty** button at the bottom
right opens it.

1. Open **Agents**, click your agent, then **Prompt** and the step to change.
2. Describe what you want to change and click **Send**. Setty reads the whole text of the step, every time.
3. Optional: to show it where to look, click **Rewrite** on a section, or **Section** under the message box to pick one or more.

The sections you pick are a hint, not a limit. When your request is about the
whole text, for example translating it or changing the tone, Setty changes the
other sections too and says so. It can rewrite a section, rename it, add one,
or remove one when you ask.

Setty edits the draft directly. Its message starts with **Done.**, says what
it did and lists the sections it touched, with "New" or "Removed" before the
ones it added or removed. In the text, each changed section is marked
**Changed by Setty**, with **Show** to compare before and after, **Undo** and
**Keep**. Under its message, **See the changes** shows everything that
changed, and **Undo** puts every section back as it was. Your variables are
protected: an edit that removes one is refused, and nothing changes.

Each edit uses 1 assistant credit: Setty shows your balance, for example
"40 credits · 1 per edit". Nothing Setty writes is live until you click
**Publish**. See [Plan & billing](/dashboard/billing/).

## When Setty asks a question, or answers without changing anything

In the **Prompt** tab, Setty does not always change your text. These answers
cost no credit.

- Your request is too vague ("make it better") or a fact is missing (a price, an address, a link): Setty asks 1 or 2 short questions and offers 2 to 4 answers to tap. Tap one or write your own, and the edit starts from there.
- You ask about your agent or the text, for example "what does my agent do when someone asks the price?": Setty answers from the text, changes nothing, and offers up to 3 edits to tap.
- Setty finds nothing to change for your request: it says so and asks what you would like to see differently. Nothing changes.

To write to Setty you need at least 1 credit left, even for a question.
Without any credit, Setty says so instead of answering: see
[Plan & billing](/dashboard/billing/).

## Apply a style to an agent

A style is learned from your real messages and makes the agent write like you.
It is placed in the agent's instructions and reaches real conversations once
you publish.

1. Open **Agents**, click your agent, then **Settings** and **Style**.
2. Choose a style in the **Style** list and click **Place in the prompt**. The list appears once one of your styles is ready.
3. The **Prompt** tab opens on **Conversation**. When the text changes, the section that received the style is marked **Style placed here**, with **Show**, **Undo** and **Keep**.
4. Read it, test if you like, then click **Publish**.

Back in **Settings**, the sentence under **Style** says where the agent
stands: it writes with the tone described in its prompt, the style is chosen
but the prompt is not published with it yet, or it writes with the style.

To remove a style, choose **No style (the prompt's tone)**, click
**Place in the prompt**, then publish. A style sets how the agent writes, not
the language it answers in. Creating a style is covered in
[My Styles](/dashboard/styles/).

## Know whether your text is live

Open **Agents**, click your agent, then **Prompt**. The badge on the right of
the steps describes the text on screen.

| Badge | Meaning |
|---|---|
| **Live** | Your agent uses exactly this text. |
| **Changed, not live** | You changed the text. The changes are not used yet: save a draft or publish. |
| **Draft, not live** | You are looking at a saved draft or at an earlier version. Your agent does not use it. |
| **Not live yet** | This text was never published. |
| **Saved, live** | On **Follow-ups** only: follow-ups save themselves and apply right away. |

Click the badge to open the version history. **First message** and
**Conversation** each have their own state: one can be live while the other
holds a draft.

A draft reaches your leads only once you publish it. When in doubt, click
**Publish**: it is the action that puts a text live.

## Save a draft without publishing

Open **Agents**, click your agent, then **Prompt**. As soon as you change the
text, two buttons appear before **Publish**:

- **Save draft** keeps your text as a new version without putting it live. Your agent keeps using the live version. On a smaller screen the button reads **Save**.
- **Discard all** throws your unsaved changes away. On a smaller screen it is an arrow with the tooltip **Discard**.

The **Test** tab uses your saved draft by default, so you can try a change
before your leads see it. Changes that are not saved are not tested.

If you leave the tab with unsaved changes, the window **Unsaved changes**
offers **Save and continue**, **Discard and continue** or **Stay on page**.
Closing or reloading the page asks for a confirmation too.

Follow-ups have no draft: they save themselves.

## Publish your changes

Publishing puts the text on screen live: your agent uses it right away, in its
real conversations.

1. Open **Agents**, click your agent, then **Prompt** and the step you changed.
2. Click **Publish**. The window **Publish a new version** opens.
3. Keep or change the **Version name**. It is prefilled with the date.
4. Check the comparison with the live version, shown when there is one.
5. Click the button that carries the version number, for example **Publish v4**.

**First message** and **Conversation** are published separately: publish each
step you changed. An empty text cannot be published.

Publishing deletes nothing. Every earlier version stays in the history and can
be brought back.

> **Published means used right away**
There is no delay: the next message your agent writes follows the published
text. Test first when the change is large.

## Go back to an earlier version

Every saved draft and every publication adds a version. The first message and
the conversation each have their own history.

1. Open **Agents**, click your agent, then **Prompt** and the step concerned.
2. Click the status badge, or **More options** (the three dots above the text), then **Version history**.
3. In the **History** panel, versions are grouped by day. **Live** marks the one your agent uses, **In the editor** the one on screen.
4. Click a version to see what it would change in your editor.
5. Click **Bring this version back**.

The version is now in your editor, nothing more. Nothing changes for your
leads until you click **Publish**. If you had unsaved changes, the window
**Replace your changes?** lets you choose **Keep my changes**.

The panel lists the 50 most recent versions.

## Which language the agent answers in

You choose the agent's language when you create it: see
[Create your AI agent](/getting-started/agent/). It does not depend on the
language of your dashboard.

In the **Prompt** tab, that language is the variable **Language**. The texts
written at creation use it this way:

- the first message is written in the agent's language;
- in the conversation it is the default language, and as soon as the lead writes, the agent replies in the lead's language and follows every change.

These rules are sentences of the text. Edit them, for example to keep one
language whatever the lead writes, then publish.

To change the variable itself, click the **Language** chip: the window offers
Français, English and Español. It warns that the text already written stays in
its original language: ask Setty to rewrite it. For an agent created in
another language, the name of the language is written in the text itself, in
place of the chip. A style never changes the language.

## Preview what the agent reads

Open **Agents**, click your agent, then **Prompt**.

- **Preview**, above the text, shows the text as your agent reads it, with your values in place of the chips. It is read only. Sections that are off are left out, and a line says how many.
- **More options**, then **Source code (markdown)**, shows the raw text. Each line that starts with `##` is the title of a section, and a variable is written `{{name}}`. To come back, open **More options** again and click **Leave the source code**.
- **Full screen** gives the whole window to the text and to Setty. **Exit full screen** brings the menu back.

## Deciding when a lead is qualified

In **Leads**, the agent sets the stage **Qualified** by itself. It decides from
the text of its **Conversation** step: what it must get from the lead (its
goal) and when it offers the next step (the path of the conversation). In the
texts written at creation, these are the sections "Your goal" and "The path".
An older prompt may have a "Qualification criteria" section instead.

1. Open **Agents**, click your agent, then **Prompt**, and stay on **Conversation**.
2. Change what the lead must have said or shown before the next step: in the goal, the path or the criteria.
3. Click **Publish**. The agent follows the new text from its next message.
4. Click **Test** and play a lead. Under each reply, **Why this answer** shows the criteria the analysis read, and **Stage in Leads** the stage the agent would set.

A lead that is already qualified stays qualified: the analysis no longer reads
the criteria for it. To qualify one lead yourself, change its stage in
[Leads](/dashboard/leads/). A label never qualifies a lead: see
[Agent labels](/dashboard/labels/).

## Test a change before publishing it

1. Open **Agents**, click your agent, then **Prompt**, and make your change.
2. Click **Save draft**, shortened to **Save** on a smaller screen.
3. Click **Test** at the top of the page.
4. Play the lead. Under **Version tested**, the test says that it uses your draft and that your live agent does not change.
5. When the result suits you, come back to **Prompt** and click **Publish**.

The test costs assistant credits and sends nothing to your real contacts. See
[Test your agent](/dashboard/playground/).

## The prompt in the API and with an AI assistant

The texts of this tab can also be read and changed from your own tools.

- `GET /campaigns/{id}/prompts` reads what an agent runs on: its texts, what is published and the values of its variables.
- `PUT /campaigns/{id}/prompts/{type}` changes a text. It is published at once, like **Publish**, and each change of **Conversation** or **First message** is a version you can restore.
- With the MCP server, you can ask an assistant why an agent said something, then let it propose the correction.

See [API: agent prompts](/developers/guides/prompts/) and [MCP server](/developers/mcp/).

## Related

- [Agents](/dashboard/agents/)
- [Test your agent](/dashboard/playground/)
- [Automatic follow-ups](/dashboard/follow-ups/)
- [My Styles](/dashboard/styles/)
