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/data-wise/craft/refinegit clone --depth 1 https://github.com/Data-Wise/craftWhat 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.00006 | $0.00675 |
| Opus 5 | $0.00003 | $0.00338 |
| Sonnet 5 | $0.00001 | $0.00135 |
| Haiku 4.5 | $0.00001 | $0.00068 |
Grade A, and why
refine 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 yesterday.
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 — 51 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/refine - Prompt Optimizer
This command is a thin shim. The canonical behavior lives in the
prompt-refinerskill. This file exists only to preserve the explicit/craft:refineslash entry point through the v2.34.0 → v3.0.0 migration (see ADR-002, which treats/refineas a separate consolidation intoprompt-refiner, distinct from the sixadhd-workflowcommands).
When invoked
- Load the canonical procedure: read
${CLAUDE_PLUGIN_ROOT:-.}/skills/workflow/prompt-refiner/SKILL.mdand follow it exactly — read context, rewrite, show the before/after box AND the fenced copy-paste-ready refined-prompt block (both as visible response text, before the confirm question), confirm via AskUserQuestion (Execute now / Copy for elsewhere / Edit first / Skip), return the chosen prompt. With no downstream command (standalone/refine "..."), stop after the confirm step regardless of which option is chosen — there is no caller to hand the result to.Note:
prompt-refinerwon't appear in the Skill tool's available-skill list (it's a nested, non-command-shaped skill) — invoke it by reading the file directly, not by guessing a Skill-tool name. - Do not reimplement here. Any change to
/refinebehavior — including the optional--explainrationale mode — must be made in the skill, never duplicated into this shim.
Why this is a shim
/refine is consolidated into a skill under the v2.34.0 → v3.0.0 migration
(ADR-002) — a separate consolidation from the six commands/workflow/*.md
commands (done/recap/next/focus/stuck/spec-review) that route into
the adhd-workflow skill. Both entry paths — the explicit
/craft:refine slash command and the --refine flag on
brainstorm/do/orchestrate/plan:feature/arch:plan — now route to the same
prompt-refiner skill. The canonical body lives in the skill, not here.
Scope note: the pre-consolidation version of this command also had
clipboard-copy and background-task-execution ("execute in background, check
status via task-status/task-output") features. Those are command-routing
concerns, not prompt-refining, and were intentionally dropped rather than
ported — the skill's job is to rewrite the prompt and hand it back, not to
execute or manage it. If background execution of a refined prompt is wanted,
that belongs in the calling command (e.g. /craft:do --refine), not here.
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.
- yesterday First seen · 51 lines · 6 tokens per session scan A a409f1b98740
refine is a command published in the GitHub repository Data-Wise/craft (4 stars, last pushed 16d ago), licensed MIT. It adds 6 tokens to every session and 675 once invoked, about $0.0000 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
readme-audit
Audit a README's reading flow by treating it as a conversion funnel. Every section is evaluated against a target reader and a terminal action. Produces a structured audit blueprint that feeds directly into /readme-restructure.
readme-restructure
Execute a /readme-audit blueprint. Rewrites the README to the evaluator → conversion → links structure and creates linked docs by extracting and reorganising existing content.
build-fix
Fix build and type failures with minimal diffs.
checkpoint
Record a verified checkpoint before the next phase.
doctor
Check the install surface for missing files and invalid manifests.
feature-dev
Drive a feature from plan to implementation to review.