The agent autoloop kit: Claude Code works alone and only pings you to decide
The short version
agent-autoloop is a free, open-source background hub for command-line agents like Claude Code and Codex. Something happens (a schedule fires, a new GitHub issue opens), it hands the job to your agent in the folder you choose, and the agent does the work. You hear nothing unless there is a decision only you should make.
The clever part is the pause. When the agent needs you, it ends its round with a question, the hub sends you a card with numbered options, and the agent process quits. Nothing is running for it and nothing spends tokens while you think. Answer with one number and the hub picks the same conversation back up and finishes the job.
| What | The detail |
|---|---|
| Asks you before | Deleting data, restarting a service, spending money, messaging anyone |
| Tokens while it waits | Zero, the agent process has exited (a light hub stays up) |
| Wakes up on | A schedule, a new GitHub issue, an error report |
| Install | One line, then agent-autoloop try |
| GitHub stars | 4,054 |
| Price | Free (MIT, open source) |
Source: the agent-autoloop GitHub repository (README in English and Chinese), read 8 Nov 2026, release v1.6.4; stars from the GitHub API that day.
Your links
| What | Link |
|---|---|
| The repo (README, install, rules, recipes) | github.com/KKKKhazix/agent-autoloop |
Install
You need Node 24 or newer, Git, and a command-line agent that is already signed in. No GitHub account needed to try it.
# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/KKKKhazix/agent-autoloop/main/install.sh | sh
# Windows PowerShell
irm https://raw.githubusercontent.com/KKKKhazix/agent-autoloop/main/install.ps1 | iex
# run the whole loop once on your own agent
agent-autoloop try
try asks you a question on purpose, you answer (type the number, or agent-autoloop answer 1 2), and agent-autoloop status shows it resume and finish, with the day's rounds, tokens and cost.
Copy these prompts
Paste them into Claude Code, in this order.
1. Write your first rule
I installed agent-autoloop. Open ~/.agent-autoloop/rules.json and add one rule that runs every weekday at 9am in my project folder and writes a short brief of yesterday's commits and open issues to BRIEF.md. Use my Claude Code agent from the agents block. Then run agent-autoloop check on the file and show me the result.
2. Decide what it must ask about
Read my project and list every action an agent could take here that I would want to approve first: anything that deletes data, restarts a service, spends money, or sends a message to another person. For each one, write the exact sentence I should put in the rule's prompt so the agent stops and asks me with numbered options instead of doing it. Do not change any files yet.
3. Hand it the GitHub issues
Set up agent-autoloop to react to new GitHub issues on my repo. Register the github source as the skill file describes, then add a rule for issues.opened that reproduces the bug locally, writes a fix on a new branch and sends me a card. It must not commit to main, push, or reply on the issue without asking me first. Preview it with agent-autoloop emit issues.opened --dry-run and show me who it would go to.
How one job runs
| Step | What happens |
|---|---|
| 1. Event in | A schedule, a GitHub issue, an error report |
| 2. Rule picks it up | The rule says which agent, which folder, which prompt |
| 3. Agent works | One round, then the agent exits |
| 4. Asks only when unsure | A card with numbered options, sent to you |
| 5. You pick | One number, and it resumes the same conversation |
Starter rules file
Rules live in ~/.agent-autoloop/rules.json and reload within seconds. A morning brief at nine (change to to the name of your Claude Code agent in the agents block):
{
"name": "morning brief",
"when": { "cron": "0 9 * * *" },
"to": "claude",
"cwd": "~/notes",
"prompt": "Go through yesterday's notes and commits and write today's brief. Before deleting anything, restarting anything, spending money or messaging anyone, stop and ask me with numbered options."
}
And one that reacts to a new GitHub issue (register the github source first):
{
"name": "handle issue",
"when": { "source": "github", "types": ["issues.opened"] },
"to": "claude",
"cwd": "~/code/app",
"skill": "handle-issue",
"parallel": 3
}
Useful commands: agent-autoloop check <file> validates a draft, agent-autoloop emit <type> --dry-run previews who an event goes to, agent-autoloop pause <rule> stops one, agent-autoloop run <rule> runs one now.
Where the card reaches you
A desktop notification is on by default. Feishu, DingTalk, WeCom, Slack and Discord also work; those use an answer link, so set hub.publicUrl to an address your phone can open. The CLI can show and answer cards too.
Steal this for your app
- The ask-first list is the whole trick. Four kinds of action need you: deleting, restarting, spending, messaging. Everything else the agent should just do. Write that list down for your own project before you let any agent run unattended.
- Make the question cheap to answer. Numbered options beat an open question, because you can answer from your phone in one tap.
- Waiting should cost nothing. If your agent setup keeps a session open while it waits for you, you are paying for it to sit there.
Good to know
- The README says Claude Code, Codex and ACP agents were tested end to end. Slack, Discord, DingTalk and WeCom were only tested against a local mock, so test the card on your channel before you rely on it.
- Some CLI text is still in Chinese; the README shows it in English.
- Vendors usually point high-frequency automation at API keys rather than personal subscriptions. Check Anthropic's current terms before running it around the clock.
- Text from an issue is never pasted into the prompt, only ids, types and links, and an event cannot pick its own agent, folder or permissions. Work agents hand to each other stops after 8 hops and you get a card.
Run this on your codebase
Look at the jobs I do by hand in this project every week (checking issues, writing release notes, reviewing errors, updating docs). Pick the two an agent could do alone, and for each one write an agent-autoloop rule with a schedule or event, the folder, and a prompt that lists exactly which actions must stop and ask me with numbered options. Show me both rules and the list of actions it will never take without asking.