/prompt-optimizer:optimize-claude-opus-5-promptsfrom Prompt Optimizer
Clarify and rewrite prompts or agent harnesses for Claude Opus 5, migrating from Opus 4.8 or tuning behaviors like long responses, over-narration, scope expansion, eager subagents, or over-verification.
Ships in Prompt Optimizer. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Turn rough ideas and existing prompt stacks into copy-ready prompts for Claude Opus 5. Preserve the user's intent and hard constraints, clarify genuinely blocking gaps, and keep the result no more elaborate than the task requires.
Opus 5 performs well out of the box on prompts written for Claude Opus 4.8. Most real optimization here is subtractive plus a few targeted behavior instructions, not a rewrite into a larger template.
Read references/official-guidance.md for model-specific rationale, runtime settings, and migration details. Read references/snippets.md for the copy-ready instruction blocks from Anthropic's guide. Treat the listed URLs as canonical and the prose as a dated working summary; fetch the live pages before making claims about current model IDs, parameters, availability, limits, or pricing.
Use the official model name Claude Opus 5 and the API model ID claude-opus-5. Treat Opus5, opus-5, and O5 as spelling variants unless context indicates a different product.
Identify the following from the user's message, pasted prompt, or referenced file:
Treat these as diagnostic dimensions, not mandatory prompt sections. Keep a simple prompt simple.
If the user supplies a layered prompt stack, preserve the separation between system, developer, user, and tool-description content. Do not silently move instructions between trust levels.
Ask a question only when the missing or conflicting information is blocking: two reasonable answers would produce materially different prompts, outputs, permissions, evidence, or success criteria.
Treat these gaps as blocking by default:
Do not turn blocking gaps into placeholders, invented policies, assumed access, or a provisional workflow.
Proceed when the core contract is clear and the missing detail is cosmetic or safely local. For an existing concrete prompt, preserve its contract and do not demand optional context. If the user explicitly delegates a nonblocking choice, make a conservative assumption, state it after the prompt, and continue.
When clarification is blocking:
For a prompt-tuning request, one question is usually enough: which behavior is wrong in the observed output. Do not interrogate the user about optional tone, headings, or preferences that a conservative assumption covers.
Opus 5 already does several things that older prompts had to force. Remove these before adding anything:
State plainly which removals are behavior-driven so the user can re-add anything their evals actually need.
Map the observed symptom to one lever. Copy the matching block from references/snippets.md and adapt it to the user's product voice.
| Observed behavior | Lever |
|---|---|
| Visible responses too long or over-caveated | Explicit conciseness instruction. Effort controls thinking, not visible length; lowering effort will not reliably shorten output. In a long system prompt, pair it with a short reminder near the end. |
| Too much narration during agentic work | Describe the cadence and shape of updates you want. Positive examples of the desired style beat prohibitions. |
| Files written to disk are padded or bloated | Length-calibration line for written deliverables, separate from conversational verbosity. |
| Unrequested steps, refactors, or reinterpreted tasks | Explicit scope constraint: deliver what was asked, flag a better approach in a sentence and continue, finish the whole task. |
| Too many subagents, or subagents used for trivial work | Explicit delegation criteria and a low or deterministic spawn cap; forbid delegating verification. |
| Corrections narrated for slips that change nothing | Correction threshold: correct only when the error changes the user's code, conclusions, or decisions. |
| Code review returns too few findings | Remove conservatism instructions; ask for all findings and filter in a second pass. |
| Multi-file feature work stops short or leaves stubs | Give the complete task specification up front and let the model run, instead of drip-feeding steps. |
| Charts, documents, diagrams, or UI replication underperform | Provide tools for iterative analysis, cropping, and visual verification rather than more thinking. |
| Spreadsheets or slide decks miss house style | State the specific styles, templates, and structure to follow. |
| Tool call appears as plain text (thinking disabled) | Prefer re-enabling thinking and controlling cost with lower effort. If thinking must stay off, explicitly permit a brief sentence before a tool call. |
| Internal XML tags leak into output (thinking disabled) | Prefer re-enabling thinking. Otherwise use a general instruction against internal or system XML tags; naming the tags specifically is less effective. |
Beyond these levers, apply ordinary prompt hygiene only where it materially improves the contract:
Use a role only when a specialized perspective changes the result. Use descriptive XML tags when the prompt mixes instructions, context, examples, variable inputs, or multiple documents and tags make boundaries clearer; do not wrap a simple prompt in a large XML scaffold. Use three to five diverse examples only when they encode a format, tone, classification boundary, or edge case better than prose.
For long source material, place documents near the beginning, wrap them in clear tags such as <documents>, <document>, and <document_content>, and put the query and task instructions after them. Opus 5 holds instruction following and reasoning across its 1M-token window, so position matters less than boundary clarity, but keep instructions after the data.
Never ask Claude to reveal, reproduce, or quote hidden chain of thought. Ask instead for conclusions, concise rationale, supporting evidence, assumptions, checks performed, and uncertainty.
Do not embed API settings in the copy-ready prompt unless the user explicitly asks for a complete API request or deployment configuration.
When runtime guidance is requested:
xhigh is the starting point for coding and agentic work, high for other intelligence-sensitive workloads, and low or medium are strong on Opus 5 wherever evals show quality holds;xhigh or max effort, and that max_tokens is a hard cap covering thinking plus response text;Silently run every applicable check:
If a check exposes blocking ambiguity, return to the clarity gate. Otherwise revise until every applicable check passes.
Honor the user's requested format. Otherwise use the smallest suitable response.
For a completed optimization, return:
优化后的提示词 or Optimized prompt: one copy-ready fenced block.关键改动 or Key changes: at most five concise bullets, only when useful. Name removals explicitly, with the behavior each removal targets.假设 or Assumptions: only assumptions actually made.运行时设置 or Runtime settings: only when requested or essential to the stated use case.When the user asks for prompt-only output, return only the copy-ready prompt: no headings, commentary, change notes, or Markdown fences unless a fenced block was requested.
For blocking clarification, return only a one-sentence reason, one to three questions, and an optional one-line answer template. Do not bury the questions beneath a provisional rewrite.
Answer in the user's language.
<thinking> or other internal tags in an anti-leakage instruction; use the general form.Finish only when the prompt is copy-ready, blocking ambiguity is resolved, explicit constraints are preserved, action boundaries are clear where relevant, obsolete scaffolding is gone, each remaining behavior instruction is justified, and the validation checklist passes. If those conditions cannot be met, state the smallest missing information instead of fabricating a complete prompt.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
prompt-optimization, opus-5, prompt-engineering, agent-harness
Other plugins' skills for the same job
npx claudepluginhub ichendev/prompt-optimizer-plugins --plugin prompt-optimizer11 skills in this plugin
/audit-gpt-6-astra-skillsAudit and subtractively clean Skills, AGENTS.md, and coding-agent scaffolding for GPT-6 Astra. Use when Astra stops early, loads the wrong skills, over-reads, over-tests, over-asks, or when migrating Sol-era harness instructions—not for rewriting product prompts (use optimize-gpt-6-astra-prompts)./optimize-claude-fable-5-promptsClarify and rewrite prompts for Claude Fable 5. Use when optimizing, migrating, debugging, or designing a Fable 5 / Fabel prompt (including Fable/Fabel 提示词优化)—not for Claude Opus 5./optimize-claude-sonnet-5-5-promptsClarify and rewrite prompts or agent harnesses for Claude Sonnet 5.5 (claude-sonnet-5-5). Use when optimizing, migrating from Sonnet 5, or tuning Sonnet 5.5 behaviors such as effort, initiative/scope, between_tools, JSON accuracy, progress updates, or low-effort verification (including Sonnet 5.5 提示词优化)—not for Opus/Fable prompt rewrites or bare model picking (use select-claude-models)./optimize-deepseek-v4-promptsClarify and rewrite prompts for DeepSeek-V4 Pro and Flash. Use when optimizing, debugging, migrating, or designing a DeepSeek-V4 prompt (including DeepSeek / DeepSeek-V4 提示词优化); keep reasoning modes and special tokens outside prompt prose./optimize-gemini-promptsClarify and rewrite prompts for the Gemini model family. Use when optimizing, debugging, migrating, or designing a Gemini prompt (including Gemini 提示词优化), especially multimodal or long-context cases./optimize-glm-promptsClarify and rewrite prompts for the GLM / 智谱 model family. Use when optimizing, debugging, migrating, or designing a GLM prompt (including GLM 提示词优化 or 智谱提示词优化).