Prompt Improver
severity1/claude-code-prompt-improver
This skill enriches vague prompts with targeted research and clarification before execution.
Rewrite a vague prompt into a rich, structured one, with automatic fallback.
$ npx skills add davekilleen/Dex --skill prompt-improver -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install davekilleen/Dex prompt-improver --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/prompt-improver .claude/skills/prompt-improver && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .claude/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improverType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add davekilleen/Dex --skill prompt-improver -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install davekilleen/Dex prompt-improver --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/prompt-improver .agents/skills/prompt-improver && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .agents/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add davekilleen/Dex --skill prompt-improver -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install davekilleen/Dex prompt-improver --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/prompt-improver .cursor/skills/prompt-improver && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .cursor/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/davekilleen/Dex.git --path .agents/skills/prompt-improver--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add davekilleen/Dex --skill prompt-improver -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install davekilleen/Dex prompt-improver --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/prompt-improver .gemini/skills/prompt-improver && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .gemini/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install davekilleen/Dex prompt-improverInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add davekilleen/Dex --skill prompt-improver -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/prompt-improver .github/skills/prompt-improver && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .github/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add davekilleen/Dex --skill prompt-improver -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install davekilleen/Dex prompt-improver --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/davekilleen/Dex.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/prompt-improver .opencode/skills/prompt-improver && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "prompt-improver" agent skill from https://github.com/davekilleen/Dex/tree/main/.agents/skills/prompt-improver into .opencode/skills/prompt-improver/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "prompt-improver", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
prompt-improverRewrite a vague prompt into a rich, structured one, with automatic fallback.
Prompt Improver is an agent skill from davekilleen/Dex. Rewrite a vague prompt into a rich, structured one, with automatic fallback. Use when the user says 'improve this prompt', 'make this prompt better', or hands over a thin instruction. Not for creating a reusable skill; use create-skill.
Its SKILL.md is about 1.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in AI & LLM Engineering, covering Prompt engineering. The repository describes itself as: Your AI Chief of Staff — a personal operating system starter kit that adapts to your role. No coding required. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit d0ffc6b. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
nodeFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
ANTHROPIC_API_KEYFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Prompt Improver loads about 1.9k tokens when it runs. Until then it costs about 64 tokens; SKILL.md has 697 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
r best results, add ANTHROPIC_API_KEY to .env"`1. Create `.env` file in vault root (if not exists)3. Make the file owner-only: `chmod 600 .env` (API keys should never be readable by other users of the machine)Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from davekilleen/Dex at commit d0ffc6b, republished under its MIT licence (© davekilleen). 697 words, ~1,857 tokens.
.claude/skills/prompt-improver/SKILL.md (or your agent's skills folder).<!-- Generated from `.claude/skills/prompt-improver/SKILL.md` by `scripts/generate-agents-skills.py`. Do not edit. -->
Transform vague, ambiguous prompts into rich, well-structured prompts. Uses Anthropic's prompt improvement capabilities when available, with graceful fallback to the current LLM.
How it works:
$PROMPT - The prompt to improve (required) $FEEDBACK - Optional feedback on what to improve (e.g., "Make it more detailed", "Add examples", "Focus on clarity") $TARGET_MODEL - Optional target model for the improved prompt (defaults to current model) $SYSTEM - Optional system prompt to improve alongside the user prompt
Check if $PROMPT starts with a flag:
| Flag | Behavior |
|---|---|
-p | Prompt only - Show the improved prompt, don't execute |
-v | Verbose - Show the improved prompt, then execute |
| (none) | Quick - Execute immediately without showing full prompt |
Strip the flag from $PROMPT before processing.
Check if $PROMPT starts with a flag (-p, -v) and extract:
prompt-only, verbose, or quick (default)Check in this order:
Script available? Check if .scripts/improve-prompt.cjs exists
API key available? Check if ANTHROPIC_API_KEY is set in environment
The fallback cascade:
Script (.scripts/improve-prompt.cjs)
↓ (if not available)
Anthropic Messages API (direct call)
↓ (if no API key)
Current LLM (Opus 4.5, Sonnet, etc.)Method A: Script (preferred)
node .scripts/improve-prompt.cjs "$PROMPT" "$FEEDBACK" "$TARGET_MODEL" "$SYSTEM"Method B: Anthropic Messages API (direct) Make API call with:
claude-sonnet-4-5-20250929 (optimized for prompt engineering)Method C: Current LLM Fallback Use the current session's LLM to improve the prompt inline:
"💡 Using inline improvement (no API key configured). For best results, add ANTHROPIC_API_KEY to .env"Mode: prompt-only (flag: -p):
> **Original:** [original_prompt]Mode: verbose (flag: -v):
> **Original:** [original_prompt]<details>
<summary>📝 Improved Prompt (click to expand)</summary>
[enhanced_prompt]
</details>--- separatorMode: quick (no flag - DEFAULT):
Used for both API and fallback methods:
You are an expert prompt engineer trained in Anthropic's best practices. Your job is to transform vague, ambiguous prompts into clear, structured, effective prompts.
Analyze the user's prompt and improve it using these techniques:
1. **Structure**: Add clear sections with XML tags or markdown headers
2. **Clarity**: Be specific about format, length, and success criteria
3. **Context**: Include necessary background and define ambiguous terms
4. **Examples**: Add few-shot examples when helpful
5. **Chain of Thought**: For complex tasks, request step-by-step reasoning
6. **Constraints**: Make implicit constraints explicit
Return ONLY the improved prompt. Do not explain your changes or add meta-commentary.
{if $FEEDBACK exists: "Focus on: {$FEEDBACK}"}/prompt-improver -p critique this strategy doc
→ Shows improved prompt only, doesn't execute
/prompt-improver -v critique this strategy doc
→ Shows improved prompt, then executes it
/prompt-improver critique this strategy doc
→ Just executes the improved prompt
/prompt-improver -v "review this code" "Focus on security issues"
→ Shows improved prompt focused on security, then executesThe improved prompt typically follows this structure:
# Task
[Clear statement of what to do]
# Context
[Background information needed]
# Instructions
1. [Step 1]
2. [Step 2]
3. [Step 3]
# Constraints
- [Constraint 1]
- [Constraint 2]
# Output Format
[Expected format and structure]
# Examples (if helpful)
[Input/output examples]| Situation | Behavior |
|---|---|
| Script not found | Fall back to API |
| No API key | Fall back to current LLM with notification |
| API rate limit | Retry with exponential backoff, then fall back |
| API error | Fall back to current LLM |
| Network issues | Fall back to current LLM |
Key principle: The skill should NEVER fail completely. It always has the current LLM as ultimate fallback.
For best results, add your Anthropic API key:
.env file in vault root (if not exists)ANTHROPIC_API_KEY=your-key-herechmod 600 .env (API keys should never be readable by other users of the machine)Without the API key, the skill still works using the current LLM session.
Meta-prompting: This skill uses Claude to improve prompts for Claude. It's prompt engineering as a service.
Invisible by default: The best tools disappear. Users ask naturally, get expert results, never see the complexity.
Progressive disclosure: Flags (-v, -p) let power users inspect and learn from the improvements.
Graceful degradation: Works everywhere - with full API access, partial access, or no external access at all.
Call the mark_feature_used tool on the dex-analytics MCP server with prompt-improver. This ticks the feature's box in System/usage_log.md, which is what /dex-level-up reads to recommend features that have not been tried. It writes locally and sends nothing, so it runs whether or not analytics is enabled.
Analytics (Silent):
Call track_event with event_name prompt_improved and properties:
This only fires if the user has opted into analytics. No action needed if it returns "analytics_disabled".
© davekilleen, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .agents/skills/prompt-improver of davekilleen/Dex.
Open the folder on GitHubat commit d0ffc6b
Prompt Improver next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Prompt Improver this skilldavekilleen/Dex | 494 | — | ~1.9k | Automated safety check: Notes | MIT | |
| Prompt Improverseverity1/claude-code-prompt-improver | 1.9k | 1 repos | ~1.7k | Automated safety check: Pass | MIT | |
| Prompt Engineering Patternsynulihao/AgentSkillOS | 618 | 14 repos | ~1.7k | Automated safety check: Pass | None | |
| Patch CreationPiebald-AI/tweakcc | 2.5k | — | ~1.6k | Automated safety check: Pass | MIT | |
| Senior Prompt Engineermaslennikov-ig/claude-code-orchestrator-kit | 260 | 3 repos | ~1.4k | Automated safety check: Pass | Custom licence | |
| Codex Fable5baskduf/FableCodex | 437 | — | ~1.6k | Automated safety check: Pass | AGPL-3.0 |
severity1/claude-code-prompt-improver
This skill enriches vague prompts with targeted research and clarification before execution.
ynulihao/AgentSkillOS
Master advanced prompt engineering techniques to maximize LLM performance, reliability, and controllability in production.
Piebald-AI/tweakcc
Create and register new patches for tweakcc. An agent skill from Piebald-AI/tweakcc.
maslennikov-ig/claude-code-orchestrator-kit
Provides reference guides and Python scripts for prompt optimization, RAG evaluation, and agent orchestration when building or tuning LLM systems.
baskduf/FableCodex
Apply a Claude Fable 5 inspired operating style inside Codex.
wshobson/agents
Reference for designing and tuning production LLM prompts: few-shot examples, chain-of-thought, structured outputs, templates and system prompts.
davekilleen/Dex
This skill should be used when working with DSPy.rb, a Ruby framework for building type-safe, composable LLM applications.
davekilleen/Dex
Adopt a full published Heydex profile by handle ('set me up like @davekilleen').
davekilleen/Dex
Package one workflow — how you use Dex for a specific job — into a shareable DexDiff methodology doc.
davekilleen/Dex
Expert guidance for creating, writing, and refining Claude Code Skills.
davekilleen/Dex
Report a Dex bug to the Dex team with zero homework — Dex investigates locally, builds a privacy-safe report, shows it to you (or auto-sends if you've chosen that), and tracks the ticket until it's…
davekilleen/Dex
This skill should be used when writing Ruby and Rails code in DHH's distinctive 37signals style.
Categories
Rewrite a vague prompt into a rich, structured one, with automatic fallback. Prompt Improver is an agent skill from davekilleen/Dex. Rewrite a vague prompt into a rich, structured one, with automatic fallback.
Prompt Improver fits situations like: the user says improve this prompt; make this prompt better; hands over a thin instruction.
Run `npx skills add davekilleen/Dex --skill prompt-improver -a claude-code`. Or copy the skill folder (.agents/skills/prompt-improver in davekilleen/Dex) into .claude/skills/prompt-improver in your project. Claude Code loads it when a task matches its description.
Run `npx skills add davekilleen/Dex --skill prompt-improver -a codex`. Or copy the skill folder (.agents/skills/prompt-improver in davekilleen/Dex) into .agents/skills/prompt-improver in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add davekilleen/Dex --skill prompt-improver -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/prompt-improver, .gemini/skills/prompt-improver, .github/skills/prompt-improver and .opencode/skills/prompt-improver in your project.
Going by SKILL.md and its folder, Prompt Improver needs the command-line tools its instructions call (node) and credentials named ANTHROPIC_API_KEY. Our summary lists: A credential in ANTHROPIC_API_KEY.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.
Prompt Improver is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.9k tokens (SKILL.md is roughly 7.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Prompt Improver: Prompt Improver (severity1/claude-code-prompt-improver, 1.9k stars), Prompt Engineering Patterns (ynulihao/AgentSkillOS, 618 stars), Patch Creation (Piebald-AI/tweakcc, 2.5k stars) and Senior Prompt Engineer (maslennikov-ig/claude-code-orchestrator-kit, 260 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
davekilleen (a GitHub user) maintains it in davekilleen/Dex, which has 494 GitHub stars. The repository holds 61 skills in this directory. The repository was last updated on October 9, 2026.
Source: davekilleen/Dex on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.