Reusable AI workflows for your codebase.
Loops turns ad-hoc agent prompts into durable, repeatable workflows. Define a loop once, run it on any repo, monitor active runs, and stop them like processes.
Providers: Cursor SDK today β Claude Code coming soon. See docs/providers.md.
npm install -g @dresnite/loopsOr run without installing:
npx @dresnite/loops --help# 1. Save your Cursor API key
loops key set cursor cursor_...
# 2. Define a loop
loops add structure-agent --prompt "Improve project structure"
# 3. Run it on a repo (continuous by default)
# --model composer-2.5 β standard tier (default; use composer-2.5-fast for faster inference)
# --budget 10 β stop after ~$10 estimated model spend
# --tasks 25 β stop after 25 agent turns
loops run structure-agent --repo ./my-app --budget 10 --tasks 25
# 4. Check what's running (or see failed runs)
loops ls
loops ls --all
# 5. See what a loop is doing
loops logs structure-agent
loops logs structure-agent --follow
loops prompt show structure-agent
loops prompt set structure-agent --prompt "focus on tests next"
loops model show structure-agent
loops model set structure-agent --model composer-2.5
# 6. Stop a run (by name or run-id)
loops stop structure-agent
loops stop a1b2
# 7. Remove the definition
loops rm structure-agent--budget and --tasks are optional guardrails. Use either, both, or neither. Without limits, a continuous run keeps going until you stop it.
| Command | Description |
|---|---|
loops key set cursor <key> |
Save your Cursor API key |
loops key list |
List configured keys |
loops add <name> |
Create a loop definition |
loops run <name> |
Start a loop on a repository |
loops ls |
List running loops |
loops ls --all |
List recent runs (incl. failed) |
loops logs <name> |
View logs for a loop run |
loops prompt show <name> |
View the prompt for a run |
loops prompt set <name> |
Update the prompt for a run |
loops stop <name|run-id> |
Stop a running loop |
loops rm <name> |
Delete a loop definition |
- Getting started β install, auth, and first workflow
- Concepts β loop definitions, runs, and repo context
- Commands β full CLI reference
- Configuration β storage, credentials, budget limits
- Providers β Cursor SDK setup and roadmap
Instead of running the same prompt manually every time, you get a workflow that:
- runs inside a repo
- follows a prompt or preset file
- runs continuously or once
- starts and stops like a process
- respects optional budget and task limits
Projects using Loops to run continuous AI workflows on their codebases:
- Animoo β AI manga creation app. Runs Loops to improve stability, harden the codebase, and keep the product reliable as it evolves.
If Loops is useful to you, one way to support its development is to buy a Cursor plan through my referral link. That gives me extra tokens to keep burning on real Loops runs.
I'm not paid or sponsored to post that link here β it's just my personal referral code, and you're supporting the tool's author, not a brand deal.
Copyright (c) 2026 Andres Arias
Licensed under the MIT License. See LICENSE for the full text.