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

# Purpose and model

> Write the instructions your Agent follows, mention its inputs, skills, subagents and files, and choose the model and its advanced settings

The **Purpose** is the first section of the sidebar and the heart of the Agent: the instructions it reads before every run. The same view holds the model selector at the top.

![Purpose section with the harness badge, model selector and the editor showing a chip for an input](https://mintcdn.com/meistrari/IBJhAp-onVS37l80/images/agent/purpose.png?fit=max\&auto=format\&n=IBJhAp-onVS37l80\&q=85\&s=86e722e0bdf58997f3411142e901aed2)

## Writing the Purpose

Write the Purpose the way you would brief a capable new colleague. A good Purpose covers:

* **Role and goal**: who the Agent is and what a finished job looks like
* **How to use the inputs**: what each input contains and what to do with it
* **Steps and rules**: the order of work, what to always do, what to never do
* **When to use each helper**: which skill, subagent or file applies to which situation
* **Tone and language** of the answer

Keep the shape of the result out of the Purpose. The attributes you expect back belong in [Outputs](https://docs.tela.com/en/agent/inputs-and-outputs.md#outputs), where Tela enforces them; describing them in the Purpose only creates two sources of truth.

Here is the Purpose of the contract assistant from the [running example](https://docs.tela.com/en/agent/overview.md#the-running-example). The highlighted names are mentions, explained below:

```text theme={null}
You are a contract assistant for the legal team of a mid-size company.

The contract to analyze is the file in input/contract/. The question the
lawyer wants answered is <question>. If no question is given, summarize
the contract and list its key obligations.

Steps:
1. Read the whole contract before answering. Never guess a clause.
2. Answer the question citing the clause number and quoting the relevant text.
3. Review every clause against the risk playbook in references/risk-playbook.md
   and flag the risky ones. For termination and liability clauses, delegate the
   check to ./.claude/agents/clause-checker.md.
4. Use ./.claude/skills/clause-review/SKILL.md whenever you compare a clause
   with market standards.

Rules: write in the language of the contract, do not give legal advice beyond
the contract text, and say explicitly when the contract is silent on a topic.
```

> [!TIP]
>
> Start small: a role, the inputs and three or four rules. Run it, read what the Agent did in the **Test your agent** panel, and only then add skills, subagents and more rules for the cases that went wrong.

## Mentioning inputs, skills, subagents and files

Type `@` in the editor to open the mention menu. It lists what already exists in the Agent, grouped as **Inputs**, **Skills**, **Subagents** and **Files**. Pick an item and it is inserted as a chip, so the Agent knows exactly which input, skill, subagent or file you mean.

Because the menu only lists things that exist, declare the inputs and add the skills, subagents and files first, then write the Purpose that mentions them.

The editor placeholder reminds you of the shortcuts: *Type / for commands or @ for mentions*.

> [!NOTE]
>
> **For developers.** A chip is plain text in the Purpose file. Text inputs are written as `<inputName>`, file inputs as `input/<inputName>/`, skills as the path to their `SKILL.md` (for example `./.claude/skills/clause-review/SKILL.md`), subagents as the path to their file (for example `./.claude/agents/clause-checker.md`) and reference files by their path. The UI only renders these as chips when they are plain text surrounded by spaces or punctuation and the target exists. Do not wrap them in backticks or code formatting, or the Agent page stops recognizing them.

## Saving

Changes to the Purpose are saved with the save control of the editor or with `Cmd+S` (`Ctrl+S` on Windows and Linux). Every save creates a new version of the Agent, which you can find in the **Version History** (see [Publishing and versions](https://docs.tela.com/en/agent/publishing-and-versions.md)). An **Unsaved changes** indicator appears while you have edits that are not saved yet.

> [!WARNING]
>
> Switching between **Craft**, **Test** and **Usage** does not ask about unsaved edits. Save before leaving the Purpose editor.

## Choosing the model

At the top of the Purpose view you find a badge with the harness (**Lightweight** or **Claude Code**) and the model dropdown (**Select model**). The models offered depend on the harness: the Lightweight harness lists models from several providers, Claude Code lists Claude models. Changing the model is saved as a new version like any other edit.

Pick the most capable model while you craft, so you learn what the Agent can do, and only then try a faster or cheaper one against your test cases.

> [!NOTE]
>
> The harness itself is fixed at creation and is not changed here. To use the other harness, create a new Agent.

## Advanced settings (Claude Code harness)

With the Claude Code harness, a gear icon next to the model opens **Advanced settings**. Enabling these features may incur extra costs on Agent runs.

| Setting | What it does |
| - | - |
| **Enable thinking** | Enables the Agent's adaptive reasoning mode |
| **Reasoning effort** | Controls the trade-off between response quality, latency and cost: **Default**, **Low**, **Medium**, **High**, **Extra high** or **Max** |
| **Prompt cache duration** | How long the prompt cache stays warm between runs: **Default (5 min)**, **5 minutes** or **1 hour**. One hour doubles the cache write cost |
| **Enable workflow tool** | Under *Workflow agents*: lets the Agent decompose large tasks into parallel subagents |
| **Max duration (minutes)** | Stops a workflow-tool run after this time. The field suggests 30 |
| **Max cost (USD)** | Stops a workflow-tool run after this spend. The field suggests 10 |

Click **Save** to apply.

![Advanced settings dialog with thinking, effort, prompt cache and the Workflow agents section](https://mintcdn.com/meistrari/IBJhAp-onVS37l80/images/agent/advanced-settings.png?fit=max\&auto=format\&n=IBJhAp-onVS37l80\&q=85\&s=01c295dca2b31789517b6efdabdf35a5)

## The Lightweight Agent page

A Lightweight Agent has a different page from a Claude Code Agent. At the top of the sidebar, a switcher chooses between **Menu** (set up the Agent step by step) and **Files** (edit the Agent's files directly). In the **Menu** view the sidebar has:

* **Purpose**: the instructions and the model, as described above.
* **Settings**: four tabs, **General**, **Integrations**, **Schedules** and **Sharing**. In **General** you find the **Default model** (used on every run, unless another model is picked in the chat), the **Harness** (read-only, defined by the Agent template), the **Temperature** (from 0 to 2, when the model accepts it), the **Compaction threshold** (older messages are summarized when the context reaches this many tokens, minimum 1,000) and **Chat mode** (keeps the conversation open after the first answer).
* **References**: files the Agent reads on every run, such as templates and playbooks. Click **Upload** to add them and cite them in the Purpose with `@`.
* **Inputs** and **Outputs**: the same as in a Claude Code Agent. See [Inputs and outputs](https://docs.tela.com/en/agent/inputs-and-outputs.md).
* **Tools**: the Agent's tools, described below.

![Settings of a Lightweight Agent, General tab, with default model, harness, temperature, compaction threshold and chat mode](https://mintcdn.com/meistrari/IBJhAp-onVS37l80/images/agent/lightweight-settings.png?fit=max\&auto=format\&n=IBJhAp-onVS37l80\&q=85\&s=4a6100a0879f2671416869b601e11944)

### Tools

Each tool opens its own settings view.

**Super search** controls how the Agent searches the web. Choose **Native search** (the model's built-in search) or **Super Search**, which replaces the default with a search across several providers. With Super Search on, pick the **Providers** (**AWS**, **Google**, **OpenAI**; select at least one) and what each search returns under **Result**: **Summary with links** or **Links only**.

**Document parsing** controls how the Agent reads documents. **Extract text** reads the text layer of PDFs and Office files: it is faster, but misses scanned pages. **Extract text and recognize scanned pages** adds OCR for images and scanned PDFs: it is slower and uses more credits.

**Splitter** lets the Agent identify and extract the logical documents inside a PDF. Turn it on, and optionally add instructions for splitting (up to 2,000 characters), used either always or only as a fallback.

**Add tool** turns a published Workflow or Canvas into a tool. Pick the resource and, optionally, write a description. The inputs and their descriptions come from the published resource, and the Agent uses them to decide which values to send.

![Page of a Lightweight Agent with the Super search tool open, showing Native search and Super Search](https://mintcdn.com/meistrari/IBJhAp-onVS37l80/images/agent/tools-search.png?fit=max\&auto=format\&n=IBJhAp-onVS37l80\&q=85\&s=086ffd7aa5ad49b056272366cc9cb999)

## Conversation settings

Two switches in the header of the **Inputs** section change how a run behaves: **Chat** (multi-turn conversations) and **Auto compact** (summarizing long conversations). They are described in [Inputs and outputs](https://docs.tela.com/en/agent/inputs-and-outputs.md#chat-and-auto-compact).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.