agentleFS
fmindfmind/dot/skills/finops/SKILL.md

finops

Skill14 starsChanged yesterdayMITView on GitHub

Model cloud/AI TCO and token unit economics, set billing budgets/quotas, and audit non-human spend.

8 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Cap compute & scale-to-zero: keep min-instances = 0 on Cloud Run and preview stacks unless a latency SLO justifies idle spend.

    line 21
  2. Distinctive:

    Place static instructions/schemas before dynamic context for prompt-cache hits.

    line 26
  3. Very specific:

    Check cache-write vs TTL breakeven (reads/write >= (write_mult - 1) / (1 - read_mult)): low-reuse prefixes with paid cache writes cost more …

    line 27
  4. Distinctive:

    Separate one-time vs run-rate spend: never blend backfill or migration costs into steady-state monthly unit cost.

    line 36

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Cloud & AI FinOps

Model, bound, and verify non-human technical spend across compute, warehouses, storage, egress, observability, CI/CD, and AI inference. Delegate human effort/SOW pricing to proposal.

Workflow

  1. Audit live spend first: measure baselines across billing exports and ingest meters via gcloud/bigquery (billing exports & dry-run scan bytes), cloud-ops/databricks (warehouse/job DBU spend), and cloud-ops/pup (log/trace/metric ingest).
  2. Separate alert-only budgets from hard ceilings: billing budgets (50%, 80%, 100% actual/forecast + anomaly alerts) notify only and never stop spend. Pair them with hard service quotas, Cloud Billing spend caps, per-tenant circuit breakers, and mandatory labels (env, service, owner, cost-center) in infra-as-code.
  3. Cap compute & scale-to-zero: keep min-instances = 0 on Cloud Run and preview stacks unless a latency SLO justifies idle spend; set max-instances, concurrency, preview TTLs, and spot/preemptible batch pools.
  4. Bound warehouse, storage & egress: enforce maximum_bytes_billed and partition/cluster pruning per bigquery; add lifecycle/archive/abort-multipart/TTL rules and image retention; prefer private endpoints over NAT gateways and CDN for public assets.
  5. Control observability & CI burn: block prod DEBUG payload logs, ban high-cardinality metric labels (user_id, request_id, raw URLs), cap trace sampling/retention, cache CI layers, and skip heavy runners on doc-only diffs.
  6. Model cloud & AI TCO deterministically: fetch current pricing from primary docs (never memory) and run tco_model.py (python3 -I ~/.agents/skills/finops/scripts/tco_model.py scenario.json --json) for exact Decimal monthly/annual totals, $/1k requests, P50/P90 spikes, and one-time vs run-rate splits. Apply AI levers before scaling:
    • Route routine work to bulk/flash tiers (request-contracts).
    • Place static instructions/schemas before dynamic context for prompt-cache hits.
    • Check cache-write vs TTL breakeven (reads/write >= (write_mult - 1) / (1 - read_mult)): low-reuse prefixes with paid cache writes cost more than uncached calls.
    • Cap multi-turn $O(T^2)$ transcript growth via rolling summaries or compaction caps.
    • Set explicit max_output_tokens/thinking effort, deduplicate embeddings by content hash, and shift offline jobs to 50%-off Batch APIs.
  7. Verify figures: freeze IaC/config/model sheets and reconcile pricing, units, and totals end to end (apply risk-gated review per subagent on external models).

Gotchas

  • Uncapped autoscalers monetize bugs: retry loops without max-instances, per-tenant rate limits, and hard quotas spike bills before budget alerts fire.
  • Dynamic prefixes bust prompt caches: putting now() or per-user metadata before system prompts drops cache hits to zero (system-prompts).
  • Separate one-time vs run-rate spend: never blend backfill or migration costs into steady-state monthly unit cost.

Documentation

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.