> For the complete documentation index, see [llms.txt](https://docs.ebrain.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ebrain.ai/agents-autonomous/building-an-agent.md).

# Building an agent

An agent is a saved job that eBrain runs for you, on a schedule or on demand. Building one comes down to three things: deciding what it should do each time it runs, writing clear instructions, and saving it. This page walks through all three.

New to agents? Start with [What are Agents?](/agents-autonomous/overview.md) for the big picture, then come back here to build your first one.

## Three ways to create an agent

You can create an agent in three ways. They all produce the same kind of agent, so pick whichever fits how you like to work.

| Path                | Best when                                                                  | Where to start                                                                             |
| ------------------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ |
| **Create via chat** | You'd rather describe what you want in plain language and let Tim write it | **Create via chat** button (top right), or **Describe your own to Tim** in the empty state |
| **From a template** | You want a proven starting point you can tweak                             | **View templates** (top right)                                                             |
| **Create manually** | You want to fill in the details yourself                                   | **Create manually** in the dropdown next to **Create via chat**                            |

{% hint style="info" %}
**Recommended:** Let Tim build it. When you create via chat, Tim asks any clarifying questions, writes the instructions for you, and proposes the finished agent as an approval card you confirm. The page nudges you toward this for a reason: it is the fastest way to a well-formed agent.
{% endhint %}

## Build it with Tim

{% stepper %}
{% step %}

### Start the conversation

Click **Create via chat** (or **Describe your own to Tim** if you have no agents yet). eBrain opens the Chat page with the message box pre-filled with a starter like **"Create an agent that "** for you to finish.
{% endstep %}

{% step %}

### Describe the job

Finish the sentence in plain language, for example "review my inbox each morning and tell me what needs attention." Tim asks any clarifying questions it needs and writes the agent's instructions for you.
{% endstep %}

{% step %}

### Approve the agent

Tim proposes the agent and an **approval card** appears in the chat. Confirm it there to create the agent.
{% endstep %}

{% step %}

### Set a schedule (optional)

If you want it to run on a schedule, Tim asks where each run's result should go (here in chat, on WhatsApp, by email, or a combination) and proposes the schedule as a second confirmation card for you to approve. For more on this, see [Scheduling, running, and results](/agents-autonomous/scheduling-and-runs.md).
{% endstep %}
{% endstepper %}

You can also edit later the same way: open **Edit with Tim**, describe the change in plain language, and Tim rewrites the instructions and updates the settings.

## Start from a template

Templates are pre-written agents made by eBrain. Pick one and it fills in the instructions and a suggested schedule for you.

{% stepper %}
{% step %}

### Open the templates panel

Click **View templates**. A panel opens titled **Templates**, with the subtitle "Made by eBrain. Pick one and Tim sets it up for you."
{% endstep %}

{% step %}

### Choose a template

Each template card shows an icon, a name, a one-line description, and a suggested-schedule badge. Browse and pick the one closest to what you need.
{% endstep %}

{% step %}

### Use it and finish setup

Click **Use template**. This opens the manual form pre-filled with the template's instructions and suggested schedule. Templates don't come with a specific chat or project attached, so pick a target if you want one, then save, or hand it to Tim to finish.
{% endstep %}
{% endstepper %}

### Available templates

| Template            | What it does                                                                    | Suggested schedule |
| ------------------- | ------------------------------------------------------------------------------- | ------------------ |
| **Daily brief**     | A morning summary of what needs your attention across email, tasks and invoices | Every day at 08:00 |
| **Weekly review**   | A weekly recap of progress, blockers and what's coming up                       | Fridays at 16:00   |
| **Project monitor** | Keep an eye on a project and surface overdue or stalled work                    | Every 6 hours      |
| **Inbox triage**    | Sort and prioritize incoming email so the important things rise to the top      | Every hour         |
| **Meeting prep**    | Prepare a briefing ahead of your upcoming meetings                              | Every day at 07:30 |
| **Release notes**   | Draft release notes from completed work on a schedule                           | Thursdays at 17:00 |

## Build it manually

Prefer to fill in the details yourself? Use the form.

{% stepper %}
{% step %}

### Open the form

Click **Create manually** from the dropdown next to **Create via chat**. The dialog is titled **New agent**.
{% endstep %}

{% step %}

### Name it

Enter a **Name**. Each agent name must be unique in your workspace, so if you reuse one you'll see a clear "An agent named '…' already exists." message.
{% endstep %}

{% step %}

### Write the instructions

In the **Prompt** box (placeholder "Describe what this agent should do each time it runs…"), write a clear, specific description of the one job the agent does each run. This is the heart of the agent.
{% endstep %}

{% step %}

### Set target, delivery, and schedule (optional)

Use the pill controls to choose a **Target** (a specific chat or project the run focuses on), **Delivery** channels (where the result goes), and a **Schedule** (or leave it on demand). These are covered in detail in [Scheduling, running, and results](/agents-autonomous/scheduling-and-runs.md).
{% endstep %}

{% step %}

### Save

Click **Create**. You can't save until both a name and the instructions are filled in. Prefer to hand off? Use the **Build it with Tim** link in the form and Tim will write the instructions and pick the settings from your partial draft.
{% endstep %}
{% endstepper %}

## Writing instructions that work

The quality of an agent comes down to the quality of its instructions. Whether you write them yourself or let Tim draft them, aim for the same things.

{% hint style="success" %}
**Tips for effective agent instructions**

* **Give it one crisp, well-defined job.** A vague catch-all agent behaves unpredictably. Narrow beats broad.
* **Say what the output should look like.** A short briefing, a prioritized list, a draft reply, a summary of what needs action: be specific about the shape of the result.
* **Say where the result should go.** Decide whether it lands in chat, on WhatsApp, by email, or a combination.
* **Say what to do when something is missing.** For example, what should happen on a day with no new email.
* **Say when it should run** if you want it on a schedule.
  {% endhint %}

{% hint style="info" %}
**What an agent will and won't do.** An agent runs unattended, so there's no one in the room to approve a step mid-run. Because of that, an agent gathers and analyzes your information and produces a result for you to review and act on: a briefing, a summary, a draft, a list of what needs action. It does not send emails or create calendar events on its own. Write instructions that ask for drafts and summaries, not autonomous sending.
{% endhint %}

## After you save

Once saved, your agent appears under **Current** on the Agents page, and you can run it, schedule it, pause it, or edit it at any time.

<table data-view="cards"><thead><tr><th>Topic</th><th data-card-target data-type="content-ref">Link</th></tr></thead><tbody><tr><td>Schedule it, run it now, and read the results</td><td><a href="/pages/VB7PDIOHtqy8Ma1us2j8">/pages/VB7PDIOHtqy8Ma1us2j8</a></td></tr><tr><td>Understand what agents are and how they differ from chatting</td><td><a href="/pages/2FNhAcz3vH2jDMbaMGkQ">/pages/2FNhAcz3vH2jDMbaMGkQ</a></td></tr><tr><td>Link WhatsApp so an agent can deliver there</td><td><a href="/pages/FIBJv6fZUgUNT5RkB5cQ">/pages/FIBJv6fZUgUNT5RkB5cQ</a></td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ebrain.ai/agents-autonomous/building-an-agent.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
