prompt-optimizer

Use when a rough prompt, vague idea, or task description needs to become a finished copy-pasteable prompt for a chat-based LLM - rewrite it into one ready-to-send prompt with no blanks, no placeholders, and a clear output shape.

8 stars

Best use case

prompt-optimizer is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Use when a rough prompt, vague idea, or task description needs to become a finished copy-pasteable prompt for a chat-based LLM - rewrite it into one ready-to-send prompt with no blanks, no placeholders, and a clear output shape.

Teams using prompt-optimizer should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/prompt-optimizer/SKILL.md --create-dirs "https://raw.githubusercontent.com/drvoss/everything-copilot-cli/main/skills/workflow/prompt-optimizer/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/prompt-optimizer/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How prompt-optimizer Compares

Feature / Agentprompt-optimizerStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Use when a rough prompt, vague idea, or task description needs to become a finished copy-pasteable prompt for a chat-based LLM - rewrite it into one ready-to-send prompt with no blanks, no placeholders, and a clear output shape.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Prompt Optimizer

Prompt Optimizer turns rough prompting intent into a single reusable prompt that the
user can paste directly into a chat interface.

This is for **chat-interface prompts only** - not API parameter tuning, system prompts,
agent files, or full promptware design.

## When to Use

- The user says "rewrite this prompt", "improve this prompt", or "turn this into a prompt"
- The user has a half-formed idea and wants a strong prompt instead of a direct answer
- The user pasted a draft prompt and wants it sharpened for quality, structure, or clarity
- The user wants a reusable prompt they can send to Copilot, Claude, Codex, or another chat LLM

## When NOT to Use

| Instead of prompt-optimizer | Use |
|-----------------------------|-----|
| The user wants the answer to the task right now | answer directly |
| Designing context packs or task briefs for agents | `context-engineering` |
| Generating a new SKILL.md for this repository | `skill-creator` |

## Two Hard Rules

### 1. No placeholders

Do not output blanks like:

- `[insert X]`
- `{topic}`
- `<your input here>`

The result must be ready to send as-is. No brackets, braces, fill-in-the-blank tokens,
or other placeholder syntax should survive in the final prompt.

### 2. Always ship a finished prompt

There are only two acceptable modes:

- **Case A - real content was provided**: bake that content directly into the final prompt
- **Case B - only the task type was described**: write a self-contained prompt that asks the
  next-model turn for the missing inputs

In both cases, the user should be able to copy, paste, and send immediately.

## Workflow

### 1. Identify the real goal

Before rewriting, decide:

- what output the user wants
- who the output is for
- what constraints matter
- whether this is Case A or Case B

### 2. Choose the right amount of structure

Use simple prose for simple tasks. Use sections or tags only when the task is complex
enough to benefit from them.

Good structure helps. Unnecessary ceremony hurts.

### 3. Handle missing information the right way

If the missing details are essential and the user did not provide them:

- do not create placeholders
- instruct the model to ask a short clarifying question first
- or phrase the prompt so the user will naturally provide the input in the next turn

### 4. Be explicit about output shape

State:

- the deliverable
- the tone
- the format
- the constraints
- any verification or self-check step

If the task is high-stakes, tell the target model to re-check its answer before finishing.

### 5. End with a reasoning cue

Close the prompt with one clear instruction such as:

- `Take time to think through this carefully before responding.`

Adapt the wording to the language and tone of the prompt.

### 6. Output only the final prompt

Return a single fenced code block containing the optimized prompt.

Do not prepend explanation unless the user explicitly asked for commentary.

## Output Format

````markdown
```text
<single final prompt>
```
````

## Common Rationalizations

| Rationalization | Reality |
|----------------|---------|
| "A template with blanks is good enough." | Blank templates push the hard work back onto the user. |
| "I'll explain my changes too." | The default deliverable is the prompt, not the meta-commentary. |
| "More structure is always better." | Over-structuring simple asks makes prompts worse, not better. |

## Red Flags

- The output contains brackets or obvious variables
- The prompt assumes missing inputs without saying so
- The result is really an agent spec or system prompt instead of a reusable chat prompt
- The answer includes a long preamble before the code block

## Verification

- [ ] The output is a single ready-to-send prompt
- [ ] No placeholder syntax remains
- [ ] If inputs were missing, the prompt asks for them itself
- [ ] The response defaults to one fenced code block and nothing else

## See Also

- [`context-engineering`](../../development/context-engineering/SKILL.md) - structure task context for agents and multi-step work
- [`skill-creator`](../../development/skill-creator/SKILL.md) - turn a workflow into a repository SKILL.md

Related Skills

token-cost-optimizer

8
from drvoss/everything-copilot-cli

Use before a large Copilot task when model choice, context size, or parallelism could drive up billed usage — estimate cost pressure early and apply Copilot-specific reduction tactics before you run

verification-before-completion

8
from drvoss/everything-copilot-cli

Use before claiming any task is done — run the exact command that proves the fix works, read the output, and only then report success.

using-git-worktrees

8
from drvoss/everything-copilot-cli

Use when you need multiple branches checked out at once — create isolated working directories for parallel development without cloning the repository repeatedly

triage

8
from drvoss/everything-copilot-cli

Use when a single issue needs structured triage — classify it, reproduce if needed, request missing information, and leave a durable brief or close-out note in the tracker.

to-issues

8
from drvoss/everything-copilot-cli

Use when a plan, spec, or PRD must become an actionable backlog — break it into thin dependency-aware issues that each deliver a verifiable vertical slice

sprint-workflow

8
from drvoss/everything-copilot-cli

Use when starting a new feature, refactor, or multi-step dev task — runs the full sprint cycle (Think → Plan → Build → Review → Test → Ship → Monitor) using Copilot CLI's plan/autopilot modes.

sprint-retro

8
from drvoss/everything-copilot-cli

Use at the end of a sprint to run a data-driven retrospective — analyzes session history and git metrics to surface what shipped, what slowed you down, and concrete improvements.

security-audit

8
from drvoss/everything-copilot-cli

Use when a codebase needs a formal security audit beyond a quick scan — applies OWASP Top 10 and STRIDE threat modeling from a CSO perspective to surface systemic vulnerabilities.

release

8
from drvoss/everything-copilot-cli

Use when a sprint or feature is complete and ready to ship — tags the version, generates GitHub Release notes, runs rollout or smoke verification, and publishes to npm/PyPI/Docker registries.

outside-voice

8
from drvoss/everything-copilot-cli

Use when you need an independent second opinion before, during, or after implementation — run challenge, consult, or review mode in a direct builder-to-builder voice

llm-wiki

8
from drvoss/everything-copilot-cli

Use when research or domain knowledge keeps getting rediscovered across sessions — build a supplementary markdown wiki that compounds synthesized knowledge without replacing GitHub or committed project guidance

interview-me

8
from drvoss/everything-copilot-cli

Use when a request is underspecified and you need to discover what the user actually wants before writing a plan, spec, or code - ask one question at a time, attach your current hypothesis, and stop only after the intent is explicitly confirmed.