AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Cost Optimizer

skill-scoobydont-666-shared-claude-skills-cost-optimizer · by scoobydont-666

Unified cost awareness across Swarm operations. Claude API model routing, infrastructure electricity/TOU costs, mining profitability, cloud hosting budgets.

No reviews yet
0 installs
40 views
0.0% view→install

Install

$ agentstack add skill-scoobydont-666-shared-claude-skills-cost-optimizer

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-scoobydont-666-shared-claude-skills-cost-optimizer)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
2mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Cost Optimizer? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Cost Optimizer

Three cost dimensions: Claude API, Infrastructure, Cloud Hosting.

1. Claude API Costs

Model Pricing (per million tokens — input/output)

| Model | Input | Output | Use For | |---------------|----------|----------|--------------------------------------| | opus | $5.00 | $25.00 | Architecture decisions, adversarial review | | sonnet | $3.00 | $15.00 | Default — code edits, analysis | | haiku | $1.00 | $5.00 | Status checks, file reads, git ops |

Session-Miser Routing Rules

  • Start every session on sonnet (default)
  • Escalate to opus only for: deep reasoning, security review, complex architecture
  • Delegate to haiku subagents for: search, log tails, file reads, git status, simple transforms
  • Use effort levels: opus:low is cheaper than full opus for structured tasks

See: session-miser skill for full routing logic. See: token-miser skill for subagent cost controls.

Anti-Patterns (Avoid)

  • Using Opus for git commits or file reads
  • Not delegating read-only work to Haiku subagents
  • Running full sessions on Opus when Sonnet suffices
  • Skipping effort level specification on Opus calls

Token Tracking via Analytics Tool

# Session cost summary (use your analytics tool)
analytics-tool stats

# Cost by model
analytics-tool cost

# Dashboard (local)
open http://127.0.0.1:

# Weekly report
analytics-tool report --period week

See: budi-analytics skill for analytics implementation.

2. Infrastructure Costs

Electricity

  • TOU rates apply — peak hours cost 2-3x off-peak
  • Solar offset via Enphase IQ Gateway ()
  • Key metric: solar_net_watts — positive = free electricity (exporting)
  • When net_watts > 0: run full mining fleet, cost = $0 for that power

Mining Profitability (Hashrate Hedger)

  • Inputs: XMR spot price, network difficulty, pool hashrate, electricity rate, solarnetwatts
  • Decision: run full fleet / throttle / pause based on break-even threshold
  • Infrastructure: pool relay host (P2Pool relay), dedicated miner host (~10.5 KH/s), GPU-capable hosts (GPU-accelerated mining)
  • Never run mining on relay nodes — they are NOT miners

Service Power Draw (approximate)

| System | Draw | Notes | |------------------|---------|-------------------------------| | GPU host (idle) | ~150W | Dual GPU cards | | GPU host (mining)| ~400W+ | GPU-accelerated RandomX | | Relay host | ~35W | CPU-only, no discrete GPU | | Mining host | ~90W | High-performance CPU mining |

See: solar-energy skill for TOU and battery pre-positioning. See: crypto-monero-wizard skill for mining profitability formulas.

3. Cloud Hosting — When Required

Projected Year 1 costs (when deployed):

  • AWS/Azure app hosting: $40-80/mo
  • Ollama inference stays self-hosted on GPU infrastructure (no cloud cost)
  • PostgreSQL: RDS ~$15/mo or self-hosted on GPU infrastructure (~$0 marginal)
  • CDN/storage: minimal (<$5/mo at launch volume)

Strategy: maximize self-hosted workloads on local infrastructure before adding cloud spend.

Weekly Cost Review Checklist

  1. session-snitch stats — check session token spend vs prior week
  2. Grafana dashboard — GPU power draw trend
  3. Check solar production vs consumption ratio
  4. Review any cloud services added since last review
  5. Confirm no Opus usage for mechanical tasks (check budi by model)

Related Skills

  • session-miser — model routing decisions
  • token-miser — subagent cost enforcement
  • budi-analytics — token spend dashboards and CLI
  • solar-energy — electricity offset via solar
  • crypto-monero-wizard — mining cost/profitability

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.