sharpen

sharpen is a command for coding agents from emtcmca/promptsmith. It costs 22 tokens per session (579 once invoked), scanned A, original, Apache-2.0.

A prompt-refinement command that turns a rough task request into a complete prompt ready to paste into an AI coding agent or chat.

In plain words
What is it for?
Use it to improve one-off task requests. It can either make assumptions automatically or ask questions one at a time for a deeper refinement.
Why use it?
It helps fill in missing details and review the request before work begins, reducing misunderstandings and follow-up questions.

Command

Installs and runs on its own, but its text points at files inside its plugin — anything it tells you to read at a ${CLAUDE_PLUGIN_ROOT} path is only there once the plugin is installed. Installing the plugin gets both.

Part of the promptsmith plugin — 2 skills, 4 commands, 20 agents shipped together

Install

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.

agentmods
npx agentmods add commands/emtcmca/promptsmith/sharpen
Clone the repo
git clone --depth 1 https://github.com/emtcmca/promptsmith

Or install promptsmith, the plugin that ships this one along with the rest of its 2 skills, 4 commands, 20 agents.

Wrote 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.

agentmods badge for sharpen

README.md
[![agentmods](https://agentmods.dev/badge/commands/emtcmca/promptsmith/sharpen.svg)](https://agentmods.dev/commands/emtcmca/promptsmith/sharpen)
Your own site
<a href="https://agentmods.dev/commands/emtcmca/promptsmith/sharpen"><img src="https://agentmods.dev/badge/commands/emtcmca/promptsmith/sharpen.svg" alt="Measured on agentmods" height="20"></a>
Per session 22 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 579 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00022 $0.00579
Opus 5 $0.00011 $0.00290
Sonnet 5 $0.00004 $0.00116
Haiku 4.5 $0.00002 $0.00058

Measured 5d ago against content hash 8170792e4dd8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sharpen 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 5d 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.

commands/sharpen.md · 47 lines

What it actually says

Sharpen a one-off task request into a complete, executable prompt. Model-agnostic — the output is plain text you can paste into any agent or chat.

Step 1 — Load the engine

Read ${CLAUDE_PLUGIN_ROOT}/skills/prompt-engineering/SKILL.md in full. It defines the pipeline. This command runs that pipeline on the SHARPEN path.

Paths. ${CLAUDE_PLUGIN_ROOT} is this plugin's install directory, substituted automatically — never a literal folder in the user's project. If promptsmith was installed standalone (README Option B, no plugin root), read from ~/.claude/ instead: ~/.claude/skills/…, ~/.claude/promptsmith-templates/, ~/.claude/promptsmith-lenses/, ~/.claude/promptsmith-agents/. Never resolve these against the user's working directory.

Step 2 — Parse arguments

Parse $ARGUMENTS:

  • --lens <a,b> — explicit lenses to apply. If absent, auto-pick by topic (engine Step 5).
  • --deep — run the interactive interview instead of assuming (engine Step 7). Ask the open questions one at a time, wait for answers, then synthesize.
  • Everything else = the rough request to sharpen.

If the request is empty, ask the user what they want to sharpen and stop.

Step 3 — Run the engine

Execute engine Steps 2–7 with route = SHARPEN:

  1. Extract goal, audience, tone/feel/theme, constraints, success criteria, format, scope.
  2. Gap-fill with labeled assumptions (unless --deep, then ask).
  3. Red-team the request; turn findings into guardrails.
  4. Load and apply the selected lenses (built-in + user dirs).
  5. Synthesize using ${CLAUDE_PLUGIN_ROOT}/templates/sharpened-prompt.md.

Step 4 — Output

Lead with the Prompt block in a copy-pasteable code fence. Then, separated below it: the assumptions you made, the 1–2 push-backs worth hearing, and the open questions — ending with an offer to rerun with --deep for a deeper pass.

No preamble. The artifact comes first.

Changes

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.

  1. 5d ago First seen · 47 lines · 22 tokens per session scan A 8170792e4dd8

Subscribe to this mod's changes

sharpen is a command published in the GitHub repository emtcmca/promptsmith (2 stars, last pushed 2d ago), licensed Apache-2.0. It adds 22 tokens to every session and 579 once invoked, about $0.0001 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.