# Spec loop

> Spec loop is an open-source agent skill for developer tools. Runs an approved spec-backed plan unattended to a draft pull request. It is available on Claude Code.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code
- **Website:** https://github.com/martinffx/atelier/tree/main/skills/spec-loop
- **Repository:** https://github.com/martinffx/atelier
- **GitHub stars:** 53
- **License:** MIT
- **Skill name:** spec-loop
- **Collection:** https://github.com/martinffx/atelier
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-03

## About

Spec Loop takes an approved plan that already has a design document and a plan file, and drives it through implementation without stopping to ask questions. Work is split into batches of up to five tasks, each implemented by a fresh subagent, reviewed, and committed. When a task hits a contradiction between the plan and the code or design, a separate resolver agent recommends an answer. Answers that stay within bounds are recorded in a decisions log for the human to review later, while answers that cross bounds halt the run and send the work back to the planning or brainstorming skills.

After the batches finish, the skill runs the spec finish process in a loop: it reviews the whole branch with the code review tools, applies fixes, and repeats until no blocking findings remain. Secrets are scanned in the commits before anything is pushed, and the run ends by opening a draft pull request that links the decisions log and any follow-up items. The skill never merges, marks the pull request ready, or rewrites history.

The skill expects a Spec-backed plan in a docs/specs directory, a clean working tree with a passing test suite, and explicit authorization to commit, push and open a draft pull request. Progress is tracked in an issue tracker, so an interrupted run can only resume when one is in use.

## When your agent uses it

> Run an approved Spec-backed Plan (design.md and plan.json both present) unattended to a draft PR: implement and review each batch with fresh subagents, commit, resolve contradictions as logged Unattended Decisions instead of stopping, then review the whole branch with rq and rs until clean. Use when the user says "run it to the end", "implement everything and open a PR", or wants the plan finished without being asked questions.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/martinffx/atelier/tree/HEAD/skills/spec-loop)
- [License: MIT](https://github.com/martinffx/atelier/tree/HEAD/skills/spec-loop)

## Features

- **Unattended batch implementation:** Implements plan tasks in batches of fresh subagents, each reviewed before it is committed.
- **Logged contradiction resolution:** Resolves plan conflicts with a resolver agent and records each in-bounds answer in a decisions file.
- **Whole-branch review loop:** Repeats whole-branch code review and fixes until no blocking findings remain.
- **Secret scanning before push:** Scans each commit for secrets before pushing and stops on any hit.
- **Draft pull request creation:** Opens a draft pull request linking the decisions log and any follow-up items.
- **Budget and stop conditions:** Caps batches and halts when a task or gate fails repeatedly or a review does not converge.

## Good for

- Implement an approved spec plan end to end and open a draft PR
- Finish the remaining tasks of a plan without answering questions along the way
- Review the whole feature branch and fix findings until it is clean
- Record design contradictions encountered during implementation for later review

## Install

### Claude Code

This skill ships in the `atelier` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add martinffx/atelier
/plugin install atelier@atelier
```

Or copy only this skill to `~/.claude/skills/spec-loop`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/martinffx/atelier.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/spec-loop &&
cp -R "$tmp/skills/spec-loop" ~/.claude/skills/spec-loop &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/spec-loop` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/spec-loop` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/martinffx/atelier.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/spec-loop &&
cp -R "$tmp/skills/spec-loop" ~/.agents/skills/spec-loop &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/spec-loop` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/spec-loop` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/martinffx/atelier.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/spec-loop &&
cp -R "$tmp/skills/spec-loop" ~/.cursor/skills/spec-loop &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/spec-loop` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/martinffx/atelier.git --path skills/spec-loop
```

Or copy the folder to `~/.gemini/skills/spec-loop` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/spec-loop`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/martinffx/atelier.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/spec-loop &&
cp -R "$tmp/skills/spec-loop" ~/.copilot/skills/spec-loop &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/spec-loop` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/martinffx/atelier.git
```

Then copy `atelier/skills/spec-loop` into your agent's skills folder as `spec-loop`. Agents that support SKILL.md read one folder per skill.

## FAQ

### What does Spec loop need before it starts?

A design.md and plan.json in the spec directory, a clean working tree, a passing test suite, and an explicit authorization covering commits, pushes and opening a draft PR.

### Does Spec loop merge or mark the PR ready?

No. It excludes merging, marking the pull request ready and rewriting history, and opens only a draft PR.

### How are contradictions in the plan handled?

A resolver recommends an answer. In-bounds answers are logged in decisions.md for review in the PR; out-of-bounds answers stop the run.

### Can an interrupted run be resumed?

Only when a tracker is used to record completed tasks. Without one, the skill says a stopped run cannot resume.

### How do I install Spec loop in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/spec-loop to use it in all your projects, or to .claude/skills/spec-loop in one project. Or install the atelier plugin, which includes it: /plugin marketplace add martinffx/atelier, then /plugin install atelier@atelier.

### Does Spec loop run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Spec loop?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

### What are the best alternatives to Spec loop?

The closest alternatives to Spec loop are Spec implement, Spec driven dev, Spec finish, Spec coding and Spec compact.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Spec implement](https://ai-powered.com/skills/spec-implement): Spec implement is an open-source agent skill for developer tools.
- [Spec driven dev](https://ai-powered.com/skills/spec-driven-dev): Spec driven dev is an open-source agent skill for developer tools.
- [Spec finish](https://ai-powered.com/skills/spec-finish): Spec finish is an open-source agent skill for developer tools.
- [Spec coding](https://ai-powered.com/skills/spec-coding): Spec coding is an open-source agent skill for developer tools.
- [Spec compact](https://ai-powered.com/skills/spec-compact): Spec compact is an open-source agent skill for developer tools.
- [Spec plan](https://ai-powered.com/skills/spec-plan): Spec plan is an open-source agent skill for developer tools.
- [Implement spec](https://ai-powered.com/skills/implement-spec): Implement spec is an open-source agent skill for developer tools.
- [Spec driven dev v2](https://ai-powered.com/skills/spec-driven-dev-v2): Spec driven dev v2 is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/spec-loop
