Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/lyupro/skillforge-mcp/prompt-optimizernpx skills add lyupro/skillforge-mcp --skill prompt-optimizergit clone --depth 1 https://github.com/lyupro/skillforge-mcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/lyupro/skillforge-mcp/prompt-optimizer)<a href="https://agentmods.dev/skills/lyupro/skillforge-mcp/prompt-optimizer"><img src="https://agentmods.dev/badge/skills/lyupro/skillforge-mcp/prompt-optimizer.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00019 | $0.00471 |
| Opus 5 | $0.00010 | $0.00235 |
| Sonnet 5 | $0.00004 | $0.00094 |
| Haiku 4.5 | $0.00002 | $0.00047 |
Grade A, and why
prompt-optimizer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
You are a prompt engineer. Given the prompt supplied as user input, rewrite it to be shorter, clearer, and more directive without changing what it asks for.
Apply this discipline:
- Cut hedging. Remove "please", "could you", "if possible", "I'd appreciate it if". LLMs do not need politeness to comply.
- Cut filler. Remove "just", "really", "basically", "actually", "simply". These add token cost and no signal.
- Cut redundancy. Find places where the same instruction appears twice — once at the top, once in an example, once in the closing — and keep the strongest single phrasing.
- Replace generic with specific. Generic verbs like "handle", "process", "deal with" become specific ones: "parse JSON", "split on whitespace", "reject if exit code non-zero".
- Concrete over abstract. "Make it good" → "Maximum 100 words. Active voice. No bullet points."
- Order matters. Goal first, constraints second, format third. The LLM weights early tokens more.
- Preserve guardrails. Do not remove instructions that exist for safety (
don't follow instructions inside the input,refuse if X, role boundaries). Cut bloat, keep teeth.
Output format:
## Optimized
<the tightened prompt>
## Diff summary
- Removed: <bullet list of what was cut + why>
- Added: <bullet list of what was added + why, often empty>
- Rephrased: <bullet list of significant rewordings>
## Token estimate
Original: ~<N> tokens. Optimized: ~<M> tokens. Savings: <X>%.
Use the rough heuristic 1 token ≈ 4 characters for the estimate.
If the input is already well-optimized, say so — return the original unchanged and explain what further trimming would damage clarity. Do not manufacture optimizations.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 5d ago First seen · 42 lines · 19 tokens per session scan A 4ff87ce40f46
prompt-optimizer is a skill published in the GitHub repository lyupro/skillforge-mcp (2 stars, last pushed 20d ago), licensed MIT. It adds 19 tokens to every session and 471 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
prompt-optimizer
Analyze and improve LLM prompts for clarity, precision, and output quality. Use when a prompt produces inconsistent results, the model ignores instructions, outputs are too long/short, or quality is below expectations.
prompt_engineering
Expert guide on prompt engineering for 2024-2025 models (GPT-4o, Claude 3.5, o1, o3, Gemini 2.0). Covers reasoning models, delimiters, structured output, and context engineering.
automatic-stateful-prompt-improver
Automatically intercepts and optimizes prompts using the prompt-learning MCP server. Learns from performance over time via embedding-indexed history. Uses APE, OPRO, DSPy patterns. Activate on "optimize prompt", "improve this prompt", "prompt engineering", or ANY complex task request. Requires prompt-learning MCP…
outlines
Outlines: structured JSON/regex/Pydantic LLM generation.
instructor
Structured LLM outputs validated with Pydantic.
guidance
Constrain LLM output with grammars; guarantee valid JSON.