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 skills add Notysoty/openagentskills --skill llm-cost-optimizergit clone --depth 1 https://github.com/Notysoty/openagentskillsWrote 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/notysoty/openagentskills/llm-cost-optimizer)<a href="https://agentmods.dev/skills/notysoty/openagentskills/llm-cost-optimizer"><img src="https://agentmods.dev/badge/skills/notysoty/openagentskills/llm-cost-optimizer/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/notysoty/openagentskills/llm-cost-optimizer"><img src="https://agentmods.dev/badge/skills/notysoty/openagentskills/llm-cost-optimizer.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00031 | $0.01642 |
| Opus 5 | $0.00015 | $0.00821 |
| Sonnet 5 | $0.00006 | $0.00328 |
| Haiku 4.5 | $0.00003 | $0.00164 |
Grade A, and why
LLM Cost 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 9d 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.
How it starts
The opening of the file, as written. The whole thing — 185 lines — stays where its author put it; the contents beside it link to each section on GitHub.
LLM Cost Optimizer
What this skill does
This skill audits an LLM application's prompts, call patterns, and model selection to identify cost reduction opportunities. It covers prompt caching, model routing (right-sizing), token reduction, batching, and output length control — the techniques that typically cut LLM costs by 40–80% without sacrificing quality.
How to use
Claude Code / Cline
Copy this file to .agents/skills/llm-cost-optimizer/SKILL.md in your project root.
Then ask:
- "Use the LLM Cost Optimizer to audit our AI application."
- "How can I reduce our OpenAI API costs? Here are our prompts..."
Provide:
- Your system prompt(s)
- Approximate daily call volume
- Which model(s) you're using
- Typical input/output token counts if known
- Whether calls are real-time (low latency required) or batch (latency tolerant)
Cursor / Codex
Paste your prompts, call patterns, and current monthly spend alongside these instructions.
The Prompt / Instructions for the Agent
When asked to optimize LLM costs, audit the following areas in order of typical savings impact:
Audit 1 — Prompt Caching (savings: 50–90% on repeated prefixes)
Check: Does the system prompt stay the same across calls?
If yes, enable prompt caching. The system prompt is sent once and cached — subsequent calls only pay for the new user tokens.
# Anthropic Claude — cache_control on system prompt
response = client.messages.create(
model="claude-opus-4-6",
system=[{
"type": "text",
"text": your_system_prompt,
"cache_control": {"type": "ephemeral"} # cached for 5 minutes
}],
messages=[{"role": "user", "content": user_message}]
)
# OpenAI — automatic prompt caching for prompts > 1024 tokens
# No code change needed — cached automatically, check usage.prompt_tokens_details.cached_tokens
When it applies: Any app where the system prompt is > 1024 tokens and reused across calls. Support bots, coding assistants, document analyzers.
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.
- 9d ago First seen · 185 lines · 31 tokens per session scan A 43ac1af7e3b3
LLM Cost Optimizer is a skill published in the GitHub repository Notysoty/openagentskills (9 stars, last pushed 25d ago), licensed MIT. It adds 31 tokens to every session and 1,642 once invoked, about $0.0002 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
thought-based-reasoning
Use when tackling complex reasoning tasks requiring step-by-step logic, multi-step arithmetic, commonsense reasoning, symbolic manipulation, or problems where simple prompting fails - provides comprehensive guide to Chain-of-Thought and related prompting techniques (Zero-shot CoT, Self-Consistency, Tree of Thoughts…
prompt-engineering
Use this skill when you writing commands, hooks, skills for Agent, or prompts for sub agents or any other LLM interaction, including optimizing prompts, improving LLM outputs, or designing production prompt templates.
devlab-ai-agent-engineering
A method for designing applications that use AI agents or large language models. It separates the application into stages such as understanding input, extracting information, choosing a strategy, executing, checking results, and producing an answer.
audit-langfuse-llm
Run a PDCA quality audit on LLM/AI features: traces, prompts, costs, evals, grounding, hallucination. Use for "audit LLM quality", "check Langfuse", "audit prompts", "check AI quality", "audit AI costs", "check traces". Jailbreak/OWASP LLM → audit-llm-security. Token caps → plan-llm-cost-guardrails.
data-pipeline
Wire ETL, ingestion, cron, edge-function, and queue jobs correctly. Use for "build a pipeline", "sync X into Y", "nightly aggregation", "cron double-counts", "dedupe", "backfill", "the numbers are wrong after a retry". Bakes in idempotency, atomic writes, data contracts, dead-letter, and observability.
plan-llm-cost-guardrails
Audit an LLM-powered app for runaway-cost and quota-abuse exposure, then produce a phased guardrail plan. Use when the user says "cap my AI costs", "my LLM bill could blow up", "rate limit my AI", "token budget", "runaway agent loop", or is hardening LLM features before launch.