sharpen-prompt — Claude Code skill: install
Turns vague requests into precise prompts with context, constraints, success checks, and an output format. Use it before handing work to another assistant.
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a claude-codeWhat sharpen-prompt does
The skill reviews a request through six checks: the goal, context, scope, constraints, signs of completion, and output format. It then rewrites the request so another assistant has enough direction to perform the task on its first attempt.
When the conversation contains the missing details, the skill puts them into a short prompt in the user’s language and explains the additions in one line. It does not carry out the task unless asked. If one essential detail cannot be inferred, it asks one question rather than guessing.
The skill is available for Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, and OpenCode. In Claude Code, the installed file is ~/.claude/skills/sharpen-prompt/SKILL.md.
What it helps with
- turn a vague request into an actionable prompt
- capture missing context and task boundaries
- define a checkable completion condition
- set the required response format
- ask for one essential detail instead of guessing
Example prompts for the agent
- Rewrite this request so another assistant can complete it on the first attempt.
- Check my prompt and add the missing scope, constraints, and completion criteria.
- Turn this vague task into a concise prompt with a defined output format.
How to install sharpen-prompt
1Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a claude-code2Manually: put the files in place
~/.claude/skills/sharpen-prompt/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/sharpen-prompt/
1Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a codex2Manually: put the files in place
.agents/skills/sharpen-prompt/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a cursor2Manually: put the files in place
.cursor/skills/sharpen-prompt/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install egorfedorov/claude-context-optimizer sharpen-prompt2Manually: put the files in place
.github/skills/sharpen-prompt/SKILL.md1Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a gemini-cli2Platform CLI
gemini skills install https://github.com/egorfedorov/claude-context-optimizer --path skills/sharpen-promptManually: put the files in place
.devin/skills/sharpen-prompt/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about sharpen-prompt
How do I install sharpen-prompt in Claude Code?
Run npx skills add egorfedorov/claude-context-optimizer --skill sharpen-prompt -a claude-code, then check ~/.claude/skills/sharpen-prompt/SKILL.md.
What does sharpen-prompt do?
It turns an underspecified request into a prompt that covers the goal, context, scope, constraints, completion checks, and response format.
What happens when an essential detail is missing?
If the conversation cannot supply it, the skill asks one clarification question instead of inventing an answer. It leaves the actual task undone unless the user requests it.
Source text
SKILL.md · MIT
--- name: sharpen-prompt description: Rewrite a vague request into a precise prompt — goal, context, scope, constraints, what done looks like, output format. Use when the user asks to improve, rewrite, sharpen or check a prompt. license: MIT --- # Sharpen a prompt A precise prompt saves the back-and-forth, and the tokens, that a vague one costs. Rewrite the user's prompt so another assistant could do the task right on the first try. ## Check what the prompt is missing 1. **Goal**: what should exist or be true at the end. 2. **Context**: who it's for, what it builds on, what was tried. 3. **Scope**: exactly which files, sections, data or part of the problem. Name them. 4. **Constraints**: must keep, must avoid, length, tone, tools, deadline. 5. **Done looks like**: how to tell it worked: tests pass, a sample output, a checklist. 6. **Output format**: a list, a table, a diff, a file, a one-paragraph answer. ## Then - If you can fill the gaps from the conversation, write the improved prompt in a code block in the user's language. Keep it as short as the task allows, and list in one line what you added and why. - If one gap is essential and unknowable, ask that one question instead of guessing. Never ask more than one. - Don't do the task itself unless the user asks you to.
© egorfedorov · MIT · egorfedorov/claude-context-optimizer