> ## Documentation Index
> Fetch the complete documentation index at: https://trytilde.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Manage prompts

> Review each agent's prompt versions, compare them, see their cost and latency, and forget a prompt's history.

Prompt management in Tilde is read-only. Your agent's code owns its prompts, and `tilde deploy` registers them. The Tilde UI shows what each deployment shipped, and how each version performed.

## Review an agent's prompts

Open the agent in the Agent Registry, and select **Prompts**. Tilde lists every prompt the agent registered, with its latest version, format, variables, number of versions, and when it last changed.

Select a prompt to open it.

* **Versions** lists each version, with the commit that first shipped it.
* The template shows the version's text and sections, its format, and its variables. A dynamic prompt shows the function source that renders it.
* **Origin** shows where your code declares the prompt.
* **First shipped by** links to the deployment that introduced the version.

### Compare versions

Select **Compare with** a previous version to see a line-by-line diff of the two templates.

### See usage by version

The usage table shows, for each version:

| Column | What it shows |
| - | - |
| Requests | The model calls linked to the version. |
| Input tokens and output tokens | Their token usage. |
| Cost | Their cost, from Tilde's price list. |
| Avg latency | Their average latency. |
| Last used | When the version last produced a model call. |

Use this to compare a new prompt with the one it replaced, after a [weighted rollout](/docs/routing).

## See what a deployment shipped

Open the agent's **Deployment** tab, and select a deployment. Tilde shows the prompts, skills, and tools that deployment registered from its code.

## Change a prompt

Change the prompt in your code, and deploy. `tilde deploy` registers the new text as the next version, and the agent uses it once the new deployment serves traffic.

To roll a prompt back, promote the previous deployment. See [Routing](/docs/routing).

## Forget a prompt's history

Select **Delete history** on a prompt to remove its versions and usage from Tilde. The code still owns the prompt, so the next `tilde deploy` registers it again, as a new first version.

An agent can do the same at runtime with `ctx.prompts.delete()` in the TypeScript SDK, if you grant it the **Edit prompts** capability.

## Who can manage prompts <span className="cloud-tag">CLOUD</span><span className="enterprise-tag">ENTERPRISE</span>

Prompts have no roles of their own. They follow their agent's [operator roles](/docs/operator-access).

| Action | Needs |
| - | - |
| View an agent's prompts | `view` on the agent. |
| Delete a prompt's history | `edit_prompts` on the agent. The agent editor role includes it. |

## Agent capabilities for prompts

Grant these on an agent's **Capabilities** tab. See [IAM](/docs/iam#capability-reference).

| Capability | Lets the agent |
| - | - |
| `agents.read` | List other agents' prompts. An agent can always list its own. |
| `agents.edit_prompts` | Delete the prompt histories of the selected agents, itself included. |
