ai-agent-cost-optimizer
Installation
SKILL.md
AI Agent Cost Optimizer
Reduce AI agent spend without reducing shipped quality. Optimize for cost per correct completed task, not raw token count.
When to Activate
- AI coding bills, token usage, API inference cost, or model spend are too high
- Reviewing agent workflows for context waste, retry loops, or cache misses
- Choosing model tiers for planning, implementation, review, or cleanup tasks
- Evaluating claims about prompt caching, cheap models, or token savings
- Capturing repeated workflows so future agents do not rediscover the same context
Core Principle
Price the model and context to the cost of failure.
Use more capable models when a wrong answer could create expensive rework, security risk, data loss, or architectural drag. Use cheaper models and smaller context when the task is bounded, reversible, test-covered, or mechanical.
Do not save tokens in ways that increase retries, hide important evidence, or lower code quality.