skills/prompt-optimizer/SKILL.md
Creates, optimizes, and iteratively refines agent prompts, system prompts, developer prompts, and reusable prompt templates. Use when asked to improve a prompt, optimize a system prompt, rewrite an agent prompt, tune prompt wording, make a prompt more reliable, port prompts between OpenAI, Claude, or Gemini, or build prompt evals.
npx skillsauth add getsentry/skills prompt-optimizerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Optimize prompts with evals. Keep every instruction, example, and external context reference causal.
| Need | Read |
|------|------|
| New prompt | references/core-patterns.md, references/model-family-notes.md, references/transformed-examples.md |
| Existing prompt | references/meta-optimization-loop.md, references/core-patterns.md, references/model-family-notes.md |
| Model-family port | references/model-family-notes.md, references/core-patterns.md |
| Repeated failures | references/meta-optimization-loop.md, references/core-patterns.md |
| Weak or ambiguous draft | references/transformed-examples.md |
| Provenance | SOURCES.md |
Record before editing:
system, developer, user, tool descriptions, examples, schemasIf success criteria or examples are missing, create a small eval set first. If the bottleneck is model choice, retrieval, tool schema, or missing evals, say so before rewriting.
For repo or agent prompts, list stable context by exact path:
| Context type | Examples |
|--------------|----------|
| Agent rules | AGENTS.md, CLAUDE.md |
| Specs | specs/*.md, docs/api.md |
| Policies | SECURITY.md, docs/releasing.md |
| Examples | examples/, tests/fixtures/ |
Rules:
loaded, referenced, or out of scope.Read references/model-family-notes.md.
Read references/core-patterns.md.
system or developer.Read references/meta-optimization-loop.md for refinements.
Return:
TargetSuccess CriteriaExternal ContextOptimized PromptAdapter NotesEval SetOptimization LogResidual RisksFor existing prompts, include a concise diff-style note of the main behavioral changes.
development
Document and type a Sentry API endpoint. Write or fix @extend_schema decorators, specify response TypedDicts, type request parameters, correct type drift between the declared schema and the runtime response, and validate the generated spec. Use when asked to "document an endpoint", "add OpenAPI docs", "add/fix @extend_schema", "type an endpoint response", "fix the response type", "fix type drift", "reuse a response type", "split an overloaded endpoint", "specify the response schema", "add a TypedDict response", "migrate a legacy api-docs path", "fix a parameter type", or "make an endpoint public" / "promote an endpoint" (promotion is one section here).
documentation
Create, refresh, and rewrite PR titles and descriptions following Sentry conventions. Use when opening a PR, writing or updating a PR title/body/description, refreshing an existing PR after material changes, or preparing branch changes for review.
tools
Analyze a repository to generate recommended Claude Code settings.json permissions. Use when setting up a new project, auditing existing settings, or determining which read-only bash commands to allow. Detects tech stack, build tools, and monorepo structure.
development
Triage new issues in the Sentry `javascript` project by archiving non-actionable noise. Use when asked to "triage issues", "triage the javascript project", "archive non-actionable issues", "triage new frontend issues", or "clean up the sentry/javascript queue". Operates only on the sentry/javascript project, only archives (never resolves), and always archives with `untilEscalating`.