---
title: Objectives
description: Give a Lampson agent an objective and it works on it by itself until it's done — it plans on its board, works in rounds, keeps you informed and asks for your approval before anything irreversible.
---
# Objectives

An **objective** is something you ask an agent to work on **by itself, until it's done**: "add this feature with tests", "research X and leave me a summary", "find the cheapest price for…". It isn't a conversation: you leave it running and come back when it tells you.

The agent:

- **plans**: breaks the objective into tasks on its board and moves them along (to do → doing → done);
- **works in rounds**: it ends a turn and Lampson gives it the next one, until it calls it done;
- **reports** at milestones, and **asks** what only you know;
- **asks for your approval** before anything that leaves the project or can't be undone (merge into main, publish, buy, send an email) and waits for your answer;
- **finishes** with the result: what it did, where, and how to check it.

While it waits for your answer, it spends nothing.

## Give it an objective

In the project's **teams** screen (the **equipos** button in the web UI, `/w/<project>/equipos`, or from [all your projects](/en/docs/teams#where-you-create-them) at `http://127.0.0.1:8080/equipos`) → **+ nuevo**: pick the agent, write what it has to achieve, how often it takes a round and how much it may spend.

Or from the terminal, in the project's folder:

```sh
lampson objective add "Add filtering tasks by status, with tests. Work on your branch and ask me before merging." --agent cto
lampson objective list
lampson objective show 1
lampson objective reply 1 --approve          # or --deny, with an optional note
lampson objective reply 1 "in euros"         # answer a question
lampson objective cancel 1
```

Or through the [API](/en/docs/api#objectives): `POST /v1/objectives` with `{"agent": "cto", "text": "…"}`.

| option | | |
|---|---|---|
| `--agent ID` | who works on it | |
| `--team ID` | or a [team](/en/docs/teams) (its lead leads it) | |
| `--budget N` | tokens it may spend in total | 500,000 |
| `--round S` | seconds between one turn and the next | 20 (60 for a team) |

Out of budget, it pauses; **Seguir** (continue) gives it another equal slice.

## The screen

On the left, your objectives and their status (working, waiting for you, done, failed, out of budget). In the middle, the selected one: what it has to achieve, what it spent, its last report, the result and **its board**. On the right, the **record**: everything it did, live.

**What's waiting for you** is in the inbox: the **⚑** button in the header, on every screen, gathers the pending questions and approvals of all your projects to answer, approve or deny right there (a merge shows which branches, commits and files go in). On an objective's page, its question also shows in place, with the answer right there.

## A real objective

An agent `cto` (model `glm-5.3-flash`) on a small Node task API, with this objective:

> Add filtering tasks by status to the API: `GET /tasks?done=true` returns only the done ones and `?done=false` the pending ones (without the parameter, all of them; an invalid value is 400). With tests. Work on a new branch `cto/filtro-estado` and commit there. When it's ready and `npm test` passes, ask for approval to merge into main; with the approval, merge and finish.

**First turn** (12 steps): it set up four tasks on its board — explore the code, create the branch and implement, tests, commit and ask for approval — and closed them one by one. It created the branch, implemented the filter with two new tests, committed under its own name and asked:

> Ready to merge into main. I implemented GET /tasks?done=true|false on the branch cto/filtro-estado (commit 8bdeaf9): store.list() filters by status, the server validates the query param (invalid → 400), and I added 2 tests. npm test: 5/5 pass. Do you approve the merge into main?

Then it waited, spending nothing. We reviewed the branch, ran the tests and approved.

**Second turn** (3 steps): it merged into main and finished:

> O-1 done. GET /tasks?done=true|false implemented and merged into main (merge --no-ff of cto/filtro-estado). Changes: src/store.js, src/server.js, test/api.test.js (+2 tests). npm test on main: 5/5 pass. Without the parameter, GET /tasks still returns all of them.

About 25,600 tokens in total. (The real conversation was in Spanish; translated here.)

## To get it right

- **Say what "done" looks like**: "with tests", "npm test has to pass", "leave me a summary with sources".
- **Say what needs your approval** — even though the agent already knows, and in a team Lampson requires it anyway for merging or publishing.
- The agent works with its usual [tools and permissions](/en/docs/agents#tools-and-permissions): an objective doesn't give it more power.
- For something big, with several roles, give it to a [team](/en/docs/teams).
