# Building an AI agent (/ai--agent-builder)

/ai--agent-builder is a Claude Code skill in the AI & Agents section. Designs and implements an LLM agent in your codebase: the loop, tools, memory, stop limits and a task-level eval suite to run before shipping.

- Web version: https://skills.sgomez.dev/en/s/ai--agent-builder
- Section: [AI & Agents](https://skills.sgomez.dev/en/ai.md)
- Author: Santiago Gómez de la Torre
- License: MIT
- Source: https://github.com/sgomez-dev/claude-skills/blob/main/skills/ai/agent-builder.md
- Updated 10 Jul 2026

## Use it when

- You have a multi-step task that is hard to fully specify up front
- You want a model to call tools and keep iterating until it is done
- You need cost and iteration limits plus tests before shipping

## Not for

- Fixed-sequence tasks, where code-orchestrated calls are enough
- Coordinating several agents at once (that is what ai--multi-agent is for)

## What you get

Agent code in your repository (loop, tools, stop limits, logging) plus a suite of 10-20 test tasks, each with an automatic pass/fail check.

## How to ask for it

- `/ai--agent-builder design an agent that handles support tickets`
- `/ai--agent-builder help me define stop conditions for my agent`
- `/ai--agent-builder what tools should I expose to this agent?`

## Install

macOS · Linux:

```
curl -fsSL https://raw.githubusercontent.com/sgomez-dev/claude-skills/main/install.sh | bash
```

Windows:

```
irm https://raw.githubusercontent.com/sgomez-dev/claude-skills/main/install.ps1 | iex
```

Claude Code plugin:

```
/plugin marketplace add sgomez-dev/claude-skills
/plugin install ai-skills@claude-skills-collection
```

## Permissions

- Reads: `**/*`
- Writes: `**/*`
- Runs: `project test/eval runners`
- Network: No
- Destructive: No

## Author's description

Build an AI agent - loop design, tool surface, memory, stop conditions, evals

## Questions about this skill

### Does it always build an agent?

No. If the task is a fixed sequence of steps, it builds a code-orchestrated workflow instead. The agent loop is reserved for multi-step tasks that are hard to specify in advance and where errors are recoverable.

### What safety limits does it add?

Maximum iterations, tokens or cost per run, and a wall-clock timeout, all configurable and logged when hit. Hard-to-reverse actions such as sends, deletes and payments are gated behind explicit confirmation.

### How does it check the agent works?

With 10-20 representative tasks, each with a programmatic check on the outcome. The suite runs on every prompt or tool change and tracks success rate, iterations and cost per task.


- [How we review this](https://skills.sgomez.dev/en/methodology.md)
