Agent skill

cost-optimize

Analyze token usage patterns and recommend cost optimizations with estimated savings

rUv71,307★ · +1,002/wk · 3 repos on radarProfile →
claude-codecodexcan modify filesMIT
Install
npx skills add ruvnet/ruflo --skill cost-optimize --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 4 KB
Bundled scripts: none
Allowed tools: mcp__plugin_ruflo-core_ruflo__memory_searchmcp__plugin_ruflo-core_ruflo__memory_listmcp__plugin_ruflo-core_ruflo__memory_storemcp__plugin_ruflo-core_ruflo__agentdb_pattern-searchmcp__plugin_ruflo-core_ruflo__agentdb_pattern-storemcp__plugin_ruflo-core_ruflo__agentdb_semantic-routemcp__plugin_ruflo-core_ruflo__hooks_model-outcomeBash
Path: plugins/ruflo-cost-tracker/skills/cost-optimize/SKILL.md
Open the folder on GitHub →
Where it comes from
Source: ruvnet/ruflo
Stars: 67,015 · +629 this week
Language: TypeScript
Read our review of the source →

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# Cost Optimize Analyze recent token usage across agents and models, identify waste, and recommend specific optimizations with estimated dollar savings. ## When to use When costs are higher than expected or you want to proactively reduce spending. Analyzes model selection efficiency, cache utilization, agent redundancy, and prompt efficiency. ## Steps 1. **Load usage data** -- call `mcp__plugin_ruflo-core_ruflo__memory_search` on the `cost-tracking` namespace (last 7 days). The `memory_*` tools route by namespace; use them — not `agentdb_hierarchical-*` (which routes by tier). 2. **Analyze model fit** -- for each agent, assess whether the model tier matches task complexity: - Agents doing simple tasks (formatting, linting) on Sonnet/Opus → suggest Haiku or Agent Booster - Agents doing complex tasks (architecture, security) on Haiku → flag quality risk 3. **Check cache rates** -- compute cache hit rate per agent; if below 60%, recommend enabling or improving prompt caching (90% cost reduction on cache reads) 4. **Detect redundancy** -- look for multiple agents performing overlapping tasks, or agents being spawned for work that could be batched 5. **Estimate savings** -- for each rec

What's inside
Steps it walks through
  1. When to use
  2. Steps
  3. CLI alternative
Commands it runs
node plugins/ruflo-cost-tracker/scripts/outcome.mjs "<task-description>" <model> success
node plugins/ruflo-cost-tracker/scripts/outcome.mjs "<task-description>" <model> escalated
npx @claude-flow/cli@latest memory search --query "cost optimization strategies" --namespace cost-patterns
npx @claude-flow/cli@latest memory store --key "opt-2026-05-04" --value '{...}' --namespace cost-patterns
More from ruflo
All skills →
About this skill
What does the cost-optimize skill do?

Analyze token usage patterns and recommend cost optimizations with estimated savings

How do I install it?

Run `npx skills add ruvnet/ruflo --skill cost-optimize --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From ruvnet/ruflo, a repository with 67,015 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going