Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/juanmhidalgo/claude-pluginsWrote 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/juanmhidalgo/claude-plugins/plan)<a href="https://agentmods.dev/commands/juanmhidalgo/claude-plugins/plan"><img src="https://agentmods.dev/badge/commands/juanmhidalgo/claude-plugins/plan/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/juanmhidalgo/claude-plugins/plan"><img src="https://agentmods.dev/badge/commands/juanmhidalgo/claude-plugins/plan.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.00036 | $0.01971 |
| Opus 5.5 | $0.00014 | $0.00788 |
| Sonnet 5.5 | $0.00007 | $0.00394 |
| Haiku 4.5 | $0.00004 | $0.00197 |
Grade A, and why
plan 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 14d 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 — 220 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Refactoring Plan
Recommended: run in plan mode (
Shift+Tabto toggle) so the proposed plan is reviewed before any code changes.
Create a structured refactoring plan.
Target: $ARGUMENTS
Phase 1: Gather Context
Agent — subagent_type: "refactor:refactor-planner" (skip only if a recent analysis already covers this) to understand:
- What needs to be refactored and why
- Current test coverage
- Dependencies that could break
- Similar refactorings done in this project
Agent — subagent_type: "refactor:conflict-scout", always. Pass:
- Targets: every file and directory the refactor will touch — including the consumers that a rename would reach, not just the file being restructured.
- Symbols: the names you expect to rename, move, or delete. Leave empty only if the refactor genuinely renames nothing; the semantic-overlap scan is the half git cannot do for you.
A plan written without this scan orders the work by internal risk alone and ignores the only cost that grows while you work: someone else's branch drifting away from yours.
Phase 2: Clarify Scope
- "What's the primary goal: reduce complexity, improve testability, or prepare for a new feature?"
- "Are there parts of the code that must NOT change?"
- "What's the acceptable risk level: conservative or aggressive?"
Phase 3: Generate Plan
<output_format>
# Refactoring Plan: [target]
## Goal
[One sentence describing the end state]
## Scope
- **In scope**: [what will change]
- **Out of scope**: [what stays unchanged]
- **Risk level**: Low / Medium / High
## Concurrent Work
From the conflict scout. State its verdict verbatim; if it could not reach `gh`, say so instead of claiming a clean scan.
**Verdict**: CLEAR | CONTESTED | BLOCKED — [one sentence]
| Target | Concurrent work | Type | Handling |
|--------|-----------------|------|----------|
| `path` | PR #N "title" (@author, 12d, +340/-120) | textual — same functions | defer to Phase 3, after #N merges |
| `symbol` | PR #N calls it in `path:line` | semantic — merges clean, breaks after | land after #N, or tell @author |
| `path` | uncommitted local edits | local | commit or stash in the pre-flight checklist |
(If nothing is in flight, write exactly: "No open PRs, branches, or local edits touch these files.")
## Call Sites
Every reference to a symbol being renamed, moved, or deleted, found with Grep (not sampled). The user checks this list to confirm nothing was missed.
| Symbol | Call site | Step that updates it |
|--------|-----------|----------------------|
| `old_name` | `path/to/file.py:42` | 2.2 |
| `old_name` | `templates/x.html:7` (string reference) | 2.2 |
**Total**: [N] call sites in [M] files. Searched: [the exact patterns used, including string/dynamic forms such as `getattr`, templates, config]
(If the refactor renames, moves, or deletes nothing, write exactly: "No symbols change name or location.")
## Execution Mode
- **Step by step** (default): follow the phases below
- **Hand off to `/batch`**: when the migration is mechanical and touches many files (roughly 10+ files, or call sites that can each be updated independently), offer the built-in `/batch <instruction>`; it splits the work into independent units, each in its own worktree. Pass it this plan's Goal, the Call Sites table, and the checkpoints. Not for steps that must land in order
## Pre-Refactoring Checklist
- [ ] Tests pass before starting
- [ ] Branch rebased on the latest base — a refactor started behind conflicts twice
- [ ] Git branch created: `refactor/[name]`
- [ ] Backup or stash any uncommitted work
- [ ] Contested files from Concurrent Work confirmed still contested (PRs move fast; re-check `gh pr list` if the plan is more than a day old)
## Steps
### Phase 1: Preparation (Low Risk)
No behavior changes - just setup.
#### Step 1.1: [Add missing tests]
- **Files**: `test_file.py`
- **What**: Add tests for [uncovered behavior]
- **Why**: Safety net before changes
- **Checkpoint**: Run tests, should pass
#### Step 1.2: [Extract constants]
- **Files**: `file.py`
- **What**: Move magic numbers to named constants
- **Why**: Makes next steps easier
- **Checkpoint**: Tests pass, no behavior change
### Phase 2: Core Refactoring (Medium Risk)
Main structural changes.
#### Step 2.1: [Extract function/class]
- **Files**: `file.py`
- **What**: Extract [code block] into [new_function]
- **How**:
1. Create new function with signature
2. Move code
3. Replace original with call
4. Run tests
- **Checkpoint**: Tests pass
#### Step 2.2: [Rename for clarity]
...
### Phase 3: Cleanup (Low Risk)
Polish and documentation.
#### Step 3.1: [Remove dead code]
...
#### Step 3.2: [Update documentation]
...
## Conflict Handling
For each contested target, the plan commits to one of these — never leaves it implicit:
| Situation | Move |
|-----------|------|
| PR is small and young (<3 days, <10 files) | Do that target **first and now**; land the refactor before the PR grows |
| PR is large or long-lived | **Defer** the target to a later phase; note "blocked on #N" on the step |
| PR only *calls* a symbol being renamed | Keep a **deprecation shim** (old name delegating to new) until #N merges, then remove it in a cleanup step |
| Work is local and yours | Commit or stash it in the pre-flight checklist — no plan step needed |
A step that touches a contested file carries `**Blocked on**: PR #N` on its own line, so it is visible when the step is dispatched, not only here.
## Rollback Plan
If something goes wrong:
1. `git stash` current changes
2. `git checkout <base-branch>`
3. Investigate what broke
4. Either fix forward or abandon
## Success Criteria
- [ ] All tests pass
- [ ] [Specific metric improved: e.g., function <30 lines]
- [ ] No new linter warnings
- [ ] Code review approved
## Estimated Effort
| Phase | Time | Risk |
|-------|------|------|
| Phase 1 | [X hours] | Low |
| Phase 2 | [X hours] | Medium |
| Phase 3 | [X hours] | Low |
| **Total** | [X hours] | |
</output_format>
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.
- 14d ago Changed · +22 lines dbbc061f03c4
- 23d ago Changed 5cddac6be063
- 1mo ago Changed · +45 lines 426efc246c34
- 1mo ago First seen · 153 lines · 36 tokens per session scan A 358b926b294e
plan is a command published in the GitHub repository juanmhidalgo/claude-plugins (8 stars, last pushed 2d ago), licensed MIT. It adds 36 tokens to every session and 1,971 once invoked, about $0.0001 per session on Opus 5.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-09-03.
Other commands, from other repositories
bugfix
Bug fix workflow: root cause analysis → user review → regression test + fix via TDD.
eval
Evaluate and improve one healthcare agent's system prompt. Run up to 5 iterations of: prepare fixed questions -> answer -> judge -> improve -> re-score -> commit if better.
usage-add
PitWay: Accumulate measured planning or qa token usage onto a milestone.
speckit.tdd.plan
Derive the feature's test list by delegating to zfa tdd plan (deterministic engine); falls back to LLM-guided derivation only when zfa is unavailable.
dashboard
Generar dashboard HTML local con métricas de eficiencia del proyecto SDD.
tdd
A command that follows test-driven development (TDD), a method where you write tests before the code they check. It moves through writing a failing test, adding the smallest implementation, and then improving the code.