Borrowing it
Nothing to install: this file belongs to swarm-ai-research/swarm. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/swarm-ai-research/swarm/main/.claude/commands/retro.mdgit clone --depth 1 https://github.com/swarm-ai-research/swarmWrote 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/swarm-ai-research/swarm/retro)<a href="https://agentmods.dev/commands/swarm-ai-research/swarm/retro"><img src="https://agentmods.dev/badge/commands/swarm-ai-research/swarm/retro/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.
<a href="https://agentmods.dev/commands/swarm-ai-research/swarm/retro"><img src="https://agentmods.dev/badge/commands/swarm-ai-research/swarm/retro.svg" alt="Reviewed on agentmods" width="80" 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.00000 | $0.01925 |
| Opus 5 | $0.00000 | $0.00962 |
| Sonnet 5 | $0.00000 | $0.00385 |
| Haiku 4.5 | $0.00000 | $0.00193 |
Grade A, and why
retro 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 9d 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 — 154 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/retro
Analyze the current session for repeated workflows, pain points, or manual multi-step patterns that should become new slash commands, hooks, or specialist agents. Can be invoked mid-session or at the end.
Usage
/retro
Phase 1: Session Health Summary
Compute aggregate statistics from the conversation before mining patterns:
- Tool calls: total count, by type (git, file edit, search, test, etc.)
- Error rate: failed commands / total commands
- Corrections: times the user said "no", "undo", "actually", or re-requested
- Retries: same tool called 2+ times with minor variations
- Files touched: count of unique files read, edited, created
- Session complexity: distinct tasks attempted (estimated from user messages)
Present as a compact block:
Session Health
Tool calls: 47 (git: 18, edit: 12, search: 9, test: 5, other: 3)
Error rate: 4/47 (8.5%)
User corrections: 2
Files touched: 15 (8 edited, 4 created, 3 read-only)
Tasks: 4
Provenance Analysis
If .claude/provenance.jsonl exists and is non-empty, filter entries relevant to this session (by session_id field if present, otherwise use entries from the last 4 hours as a heuristic). Report:
Provenance (this session)
Commits tracked: 4
Docs co-staged: 2/4 (50%)
Reminders resolved: 3/5 (60%)
Reminders unresolved: 2
Where:
- Commits tracked: number of provenance entries matching the session filter
- Docs co-staged: entries where
files_changedincludes CHANGELOG.md, README.md, or AGENTS.md - Reminders resolved: sum of
docs_reminders_resolvedacross entries - Reminders unresolved: sum of
docs_reminders_unresolvedacross entries
If .claude/provenance.jsonl doesn't exist or has no matching entries, skip this sub-section silently.
Phase 2: Trajectory Decomposition
Before scanning for patterns, decompose the session into structured steps:
Step N: [thought] → [action(s)] → [observation] → [outcome: success/fail/retry]
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.
- 9d ago First seen · 154 lines · 0 tokens per session scan A dea5acfa05df
retro is a command published in the GitHub repository swarm-ai-research/swarm (41 stars, last pushed yesterday), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,925 tokens. 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.
Other commands, from other repositories
story-long-scan
A command for scanning long-form online fiction rankings on platforms such as Qidian, Fanqie, and Jinjiang, then analyzing the ranking data.
story-short-scan
A tool for scanning and analysing popular short web-fiction rankings on platforms such as Zhihu Yanyan and Fanqie Short Stories.
eval-merge
Use the Read tool to load .skill-compass/{skill-name}/manifest.json. Verify.
speckit.git.validate
Validate current branch follows feature branch naming conventions.
reflect
Curate and compress recent memory. This command reviews the last 7 days of journal entries, extracts durable insights, and updates long-term memory files. Think of it as memory maintenance -- moving important things from short-term to long-term storage.
checklist
Generate a custom checklist for the current feature based on user requirements.