sharpen-improve

sharpen-improve is a command for Claude Code from axiomantic/spellbook. It costs 40 tokens per session (1,217 once invoked), scanned A, original, MIT.

A prompt-editing command that rewrites unclear instructions so an AI executor does not have to guess about important decisions. It preserves the original purpose and records each change.

In plain words
What is it for?
It helps improve prompts for coding agents and other language-model tasks where precise instructions matter.
Why use it?
It removes ambiguity while avoiding invented requirements. When the available context is insufficient, it asks the author for clarification.

Command for Claude Code

Written for Claude Code: a Claude Code command (commands/*.md).

Good fit It helps improve prompts for coding agents and other language-model tasks where precise instructions matter.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/axiomantic/spellbook/sharpen-improve
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.

Clone the repo
git clone --depth 1 https://github.com/axiomantic/spellbook

Made for: Claude Code.

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-improve

README.md
[![agentmods](https://agentmods.dev/badge/commands/axiomantic/spellbook/sharpen-improve/github.svg)](https://agentmods.dev/commands/axiomantic/spellbook/sharpen-improve)
Your own site
<a href="https://agentmods.dev/commands/axiomantic/spellbook/sharpen-improve"><img src="https://agentmods.dev/badge/commands/axiomantic/spellbook/sharpen-improve/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.

agentmods 80×15 button for sharpen-improve

Your own site · 80×15
<a href="https://agentmods.dev/commands/axiomantic/spellbook/sharpen-improve"><img src="https://agentmods.dev/badge/commands/axiomantic/spellbook/sharpen-improve.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,217 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00040 $0.01217
Opus 5 $0.00020 $0.00609
Sonnet 5 $0.00008 $0.00243
Haiku 4.5 $0.00004 $0.00122

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

Security

Grade A, and why

sharpen-improve 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-improve.md · 135 lines

How it starts

The opening of the file, as written. The whole thing — 135 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MISSION

Take an ambiguous prompt and produce a sharpened version where an LLM executor would not need to guess on any material decision. Preserve the author's intent while adding precision.

Invariant Principles

  1. Preserve intent, add precision: Sharpening means clarifying, not rewriting purpose.
  2. Ask before inventing: If context doesn't resolve ambiguity, ask the author.
  3. Minimize changes: Touch only what's ambiguous. Leave clear sections alone.
  4. Document every change: Author must understand what changed and why.
  5. No scope creep: Adding clarification is not adding features.

Protocol

Phase 1: Audit First

Run the audit protocol from /sharpen-audit internally. Use findings as your working document. Do not output the audit report.

Phase 2: Triage Findings

Categorize each finding:

Category Action
Resolvable from context Infer the answer, note source
Resolvable from conventions Apply common convention, note assumption
Requires clarification Generate question for author

If no findings: proceed directly to Phase 5, outputting the prompt unchanged with an empty change log.

Phase 3: Clarification Round (if needed)

If any findings require clarification:

## Clarification Needed

Before I can sharpen this prompt, I need answers to:

1. **[Finding ID]**: [Original ambiguous text]
   Question: [Specific question]
   My guess if unanswered: [what I'd assume]

2. ...

Please answer these, or say "use your best judgment" for any you want me to infer.

Wait for author response before proceeding.

Phase 4: Apply Sharpening

For each finding: locate ambiguous text → draft sharpened replacement → verify intent preserved → log the change.

Read the full file on GitHub · 135 lines

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 · 135 lines · 40 tokens per session scan A a56b71ba1e28

Subscribe to this mod's changes

sharpen-improve is a command published in the GitHub repository axiomantic/spellbook (10 stars, last pushed yesterday), licensed MIT. It adds 40 tokens to every session and 1,217 once invoked, about $0.0002 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-09-03.