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.
npx agentmods add commands/vynazevedo/first-plan/reusegit clone --depth 1 https://github.com/vynazevedo/first-planWrote 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/vynazevedo/first-plan/reuse)<a href="https://agentmods.dev/commands/vynazevedo/first-plan/reuse"><img src="https://agentmods.dev/badge/commands/vynazevedo/first-plan/reuse.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 | $0.00053 | $0.00915 |
| Opus 5 | $0.00026 | $0.00458 |
| Sonnet 5 | $0.00011 | $0.00183 |
| Haiku 4.5 | $0.00005 | $0.00092 |
Grade A, and why
reuse 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 4d 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 — 110 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/fp:reuse
Query do Reuse Index invertido.
Argumentos
$ARGUMENTS - intenção em texto livre. Exemplos:
- "validação de email"
- "fetch HTTP com retry"
- "logging estruturado"
- "modal de confirmação"
Workflow
Passo 0 - BM25 engine path (v0.4.0+)
Se first-plan-engine esta disponivel (ver skill first-plan-engine-bootstrap), preferir busca BM25 sobre o indice de simbolos via skill first-plan-semantic-reuse:
ENGINE=""
for c in "${CLAUDE_PLUGIN_ROOT}/engine/bin/first-plan-engine" "${HOME}/.local/bin/first-plan-engine" "$(command -v first-plan-engine 2>/dev/null)"; do
[ -x "$c" ] && ENGINE="$c" && break
done
if [ -n "$ENGINE" ]; then
DB=".first-plan/cache/search.db"
# Re-indexar se ausente ou >= 24h velho
if [ ! -f "$DB" ] || [ $(find "$DB" -mmin +1440 2>/dev/null | wc -l) -gt 0 ]; then
"$ENGINE" index --repo . --db-path "$DB" --output-json /tmp/idx.json > /dev/null
fi
"$ENGINE" search --db-path "$DB" --query "$ARGUMENTS" --limit 10 --output-json /tmp/search.json
# Renderizar JSON como tabela markdown
# Veja skill semantic-reuse para detalhes
fi
Se sem engine OU search retornou 0 hits com score >= 3.0, fallback markdown abaixo.
Passo 1 - Pre-flight (fallback)
Verificar .first-plan/03-reuse/INDEX.md existe.
Passo 2 - Match por intenção
- Identificar categoria provável da intenção (validação, http, logging, ui, etc)
- Ler
03-reuse/INDEX.mdna categoria correspondente - Ler
03-reuse/search.jsonse intenção atravessa categorias - Buscar matches via:
- Match por keyword na intenção vs
name/purpose/tagsdos items - Categoria exata
- Categoria adjacente (e.g., "validação" -> também checar "format")
- Match por keyword na intenção vs
Passo 3 - Priorizar
Items rankeados por:
- Match exato de categoria
- Match de keyword (peso por proximidade)
usage_count(mais usado = mais provavelmente bem testado)- Recência (atualizado recentemente)
Passo 4 - Apresentar
Top items para "<intenção>"
1. <name> em <path:line>
<signature>
Propósito: <purpose>
Usado em: <usage_count> lugares
Quando reusar: <when_to_reuse>
Confidence: <score>
2. <name> em <path:line>
...
(até 5 items)
Se nenhum casa:
- Considerar criar novo (justificar no plano)
- Verificar adjacências: /fp:reuse "<intenção alternativa>"
- Refresh do índice: /fp:refresh 03-reuse
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.
- 4d ago First seen · 110 lines · 53 tokens per session scan A 62f56b48c5c9
reuse is a command published in the GitHub repository vynazevedo/first-plan (23 stars, last pushed 10d ago), licensed MIT. It adds 53 tokens to every session and 915 once invoked, about $0.0003 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-30.
Other commands, from other repositories
selfreview
Self code review before a release — four narrow reviewers over the change (or the whole repo), findings ranked, nothing edited.
gate
Run the full local gate (fmt, lint, test, build, docs, and fuzz when a parser changed) and report only what failed.
matcha:review
🍵 Review gate — risk-based code review (L0-L3). Nothing ships until this passes.
matcha:audit
🍵 Stack health check — find overlaps, waste, and risks before they become problems.
matcha:why
🍵 Intent Discovery — problem, goals, success criteria, What → Why → How before touching code.
pr-review
Review a PR across multiple dimensions (description, code, scan, tests).