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

# Agents

> Group related specs (benchmarks) and choose an agent for your project.

An agent groups specs, training history, and the serving model for a project or use case.

## Group specs by relevance

Keep specs together when they measure capabilities you want to improve in the same agent.
For example, ticket routing and response quality specs can belong to one customer-support
agent. A code-repair spec for a separate coding assistant belongs to a different agent.

Adding a dataset, testing another capability, or uploading a new spec version for the same
project can use the same agent. A distinct project or use case is a reason to create another one.
Choose a descriptive name and description so the grouping is clear to others.

## Choose or create an agent

* Use the agent explicitly selected for the project when one is provided.
* Reuse an agent when its purpose fits the project and the specs you want to group together.
* Create an agent when no existing one fits, whether the organization is empty or has agents for
  unrelated work.

Inspect the organization's agents by name and description to find a relevant destination:

```python theme={null}
from trajectory import Client

client = Client()
for candidate in client.agents.list():
    print(candidate.name, candidate.description)
```

For a new use case, create an agent:

```python theme={null}
client.agents.create(
    name="customer-support",
    description="Ticket routing and response quality for customer support",
)
```

Use the selected or newly created agent's name as `agent_name` in uploads and task diagnostics.

Create the agent before uploading if needed; upload helpers associate the spec with the
agent you choose. Continue with [Bring your spec](https://docs.trajectory.ai/guides/spec.md).


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