loop

loop is a command for Claude Code from felvieira/claude-skills-fv. It costs 30 tokens per session (2,978 once invoked), scanned A, original, Apache-2.0.

A command that repeatedly runs coding agents on a task until it is finished, with optional parallel worktrees, meaning isolated copies of a repository, and a quality pass.

In plain words
What is it for?
Use it for one autonomous task or several tasks in parallel, such as implementing a feature, adding tests, or refactoring an API. It can run with Claude or Codex and limit iterations or token use.
Why use it?
It automates iterative implementation and can separate multiple tasks so their changes do not interfere.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions Codex.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is node scripts/auto-loop.mjs "sua task aqui".

Part of the dev-team-kit-fv plugin — 72 skills, 45 commands, 16 agents, 5 hooks shipped together

Good fit Use it for one autonomous task or several tasks in parallel, such as implementing a feature, adding tests, or refactoring an API. It can run with Claude or Codex and limit iterations or token use.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/felvieira/claude-skills-fv
agentmods
npx agentmods add commands/felvieira/claude-skills-fv/loop

Made for: Claude Code.

Or install dev-team-kit-fv, the plugin that ships this one along with the rest of its 72 skills, 45 commands, 16 agents, 5 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for loop

README.md
[![agentmods](https://agentmods.dev/badge/commands/felvieira/claude-skills-fv/loop/github.svg)](https://agentmods.dev/commands/felvieira/claude-skills-fv/loop)
Your own site
<a href="https://agentmods.dev/commands/felvieira/claude-skills-fv/loop"><img src="https://agentmods.dev/badge/commands/felvieira/claude-skills-fv/loop/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for loop

Your own site · 80×15
<a href="https://agentmods.dev/commands/felvieira/claude-skills-fv/loop"><img src="https://agentmods.dev/badge/commands/felvieira/claude-skills-fv/loop.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 30 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,978 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00030 $0.02978
Opus 5 $0.00015 $0.01489
Sonnet 5 $0.00006 $0.00596
Haiku 4.5 $0.00003 $0.00298

Measured 2d ago against content hash ba4986800b6a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

loop scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/loop.md · 225 lines

How it starts

The opening of the file, as written. The whole thing — 225 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/loop — Autonomous Loop v2

Invoca scripts/auto-loop.mjs para executar uma task de forma completamente autônoma. Versão 2 adiciona suporte multi-agente (claude + codex), worktree integrado com modo paralelo, passe de qualidade configurável (polishing pass), e quick wins inspirados no gnhf.

Diferença em relação ao /auto:

  • /auto — prompt-based: Claude lê o protocolo e executa no contexto atual
  • /loop — process-based: Node.js roda o agente como subprocess, iterando até done

Uso

# Task única (default)
node scripts/auto-loop.mjs "sua task aqui"

# Em repos consumidores (instalado em .bot/)
node .bot/scripts/auto-loop.mjs "sua task aqui"

# Multi-task em paralelo (worktrees isolados)
node scripts/auto-loop.mjs --worktree --parallel 3 \
  -- "implementar feature A" \
  -- "adicionar testes módulo B" \
  -- "refatorar API C"

Flags

Flag Descrição Default
--agent claude|codex Agente a usar claude
--model <name> Modelo (apenas para claude) $CLAUDE_LOOP_MODEL se definida, senão claude-sonnet-4-5
--max-iterations <n> Cap de iterações auto (8/12/15)
--max-tokens <n> Aborta quando tokens cumulativos passam de n unlimited
--stop-when "<cond>" Encerra loop quando agente reporta condição satisfeita
--contract <path.json> Contrato formal (schemas/task-contract.schema.json) — done_when dirige conclusão, escalate_when para o loop e sinaliza pro usuário em vez do agente decidir sozinho
--polish none|light|standard|full Passe de qualidade após validation standard
--worktree Roda em git worktree isolado false
--parallel <n> Roda n tasks em paralelo (requer --worktree, max 8) 1
--no-prevent-sleep Não previne sleep do sistema durante a run false
--validate Validação completa em cada iteração false
--no-commit Não fazer commit automático ao concluir false
--push Push após commit false
--verbose Mostrar output completo do agente false
-h, --help Mostrar ajuda

Read the full file on GitHub · 225 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago Changed · +3 lines ba4986800b6a
  2. 4d ago Changed 358f7cab164c
  3. 10d ago First seen · 222 lines · 30 tokens per session scan A 2b0a4b11cdac

Subscribe to this mod's changes

loop is a command published in the GitHub repository felvieira/claude-skills-fv (23 stars, last pushed today), licensed Apache-2.0. It adds 30 tokens to every session and 2,978 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.