Getting it into your agent
This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.
/plugin marketplace add MadaraUchiha-314/the-loop/plugin install the-loopWrote 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.
[](https://agentmods.dev/commands/madarauchiha-314/the-loop/upgrade-the-loop)<a href="https://agentmods.dev/commands/madarauchiha-314/the-loop/upgrade-the-loop"><img src="https://agentmods.dev/badge/commands/madarauchiha-314/the-loop/upgrade-the-loop.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00037 | $0.03621 |
| Opus 5 | $0.00018 | $0.01810 |
| Sonnet 5 | $0.00007 | $0.00724 |
| Haiku 4.5 | $0.00004 | $0.00362 |
Grade A, and why
upgrade-the-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 6d 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.
How it starts
The opening of the file, as written. The whole thing — 215 lines — stays where its author put it; the contents beside it link to each section on GitHub.
the-loop: upgrade-the-loop
Updating the plugin from the marketplace does not guarantee that a project has all the files (or the latest schema) that the current version of the-loop needs. This command reconciles them.
Steps
-
Read versions. Compare
theLoopVersionin the project's.the-loop/manifest.yamlwith the plugin's version (${CLAUDE_PLUGIN_ROOT}/.claude-plugin/plugin.json; in Cursor,.cursor-plugin/plugin.jsonunder the plugin's install directory —${CLAUDE_PLUGIN_ROOT}below means that same plugin root). -
Reconcile files. Using
${CLAUDE_PLUGIN_ROOT}/.the-loop/manifest.yamlas the source of truth:- Create any missing managed files / directories.
- Never clobber user-owned files (
managed: false) — diff and suggest changes instead. - Templates and config schemas are internal to the-loop and are not
materialized in the project; read them from
${CLAUDE_PLUGIN_ROOT}/skills/the-loop/templates/(manifest.templatesDir) and${CLAUDE_PLUGIN_ROOT}/.the-loop/*.schema.json(manifest.schemasDir) rather than creating a.the-loop/templates/folder or a.the-loop/*.schema.jsoncopy (issue-220).
-
Clean up deprecated paths. For each entry under
manifest.deprecated, if the path is present in the project, act on it — this is how projects initialized by older versions shed the duplicated, internal-only artifacts:.the-loop/templates/, superseded by the plugin's own skill templates (issue #36), and the three.the-loop/*.schema.jsoncopies, superseded by the plugin's own schemas (issue #220 — up to 118 KB of the-loop's internals per repository). Read the entry'sreasonfirst: an entry whose reason describes a MIGRATION (e.g..the-loop/config.yaml, renamed in issue-82) is never deleted here — it is handled by step 4's rename migration, which preserves the data; only remove a path whose reason marks it as safe-to-delete. If a user has clearly added their own files under a deprecated path, surface them in the report and confirm before deleting rather than removing silently.- Only the exact paths the manifest names. A candidate that resolves outside the
project's
.the-loop/directory — a symlink, a..segment, an absolute path — is refused and reported, never deleted. Removal is name-driven; it is never inferred from a pattern. - A schema copy that differs from the plugin's shipped schema is a signal. Diff it before removing and say so in the report — somebody may have been relying on a local edit, and this is their one chance to find out. If you cannot establish that a file is a the-loop schema copy, leave it and report it under needs-user.
- Only the exact paths the manifest names. A candidate that resolves outside the
project's
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.
- 6d ago First seen · 215 lines · 37 tokens per session scan A f20fa3122f03
upgrade-the-loop is a command published in the GitHub repository MadaraUchiha-314/the-loop (4 stars, last pushed 2d ago), licensed MIT. It adds 37 tokens to every session and 3,621 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-31.
Other commands, from other repositories
receipts
Find the receipt. A dated line, or it did not happen.
ship
Seen on their staging, then live. Rollback you have run.
review-code
Agent review pass plus manual checklist for correctness, security, performance, and accessibility.
rls-plan
Supabase RLS + access-control audit + remediation plan — no SQL until approved.
decline-politely
Say no clearly and kindly, to a request, invitation, or offer, without burning the relationship or over-explaining.
devils-advocate
Stress-test an idea, plan, or decision by arguing against it honestly, to find the flaws before reality does.