cost-drift

cost-drift is a skill for Claude Code, Codex from rshade/finfocus. It costs 134 tokens per session (1,547 once invoked), scanned A, original, Apache-2.0.

A cost-monitoring workflow for Pulumi, an infrastructure-as-code tool, using the FinFocus command-line tool. It compares actual and projected resource spending, checks configured thresholds, and writes a COST_DRIFT.md report.

In plain words
What is it for?
Use it on a Pulumi project to check cost drift and identify resources that need attention. It can also explain when the required CLI, billing plugin, or supported input is unavailable.
Why use it?
It helps find cloud resources whose spending has moved away from the expected amount and records likely causes and trends. It avoids treating missing cost data as proof that there is no drift.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it on a Pulumi project to check cost drift and identify resources that need attention. It can also explain when the required CLI, billing plugin, or supported input is unavailable.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/rshade/finfocus/cost-drift
Install

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.

Any agent
npx skills add rshade/finfocus --skill cost-drift
Clone the repo
git clone --depth 1 https://github.com/rshade/finfocus

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for cost-drift

README.md
[![agentmods](https://agentmods.dev/badge/skills/rshade/finfocus/cost-drift/github.svg)](https://agentmods.dev/skills/rshade/finfocus/cost-drift)
Your own site
<a href="https://agentmods.dev/skills/rshade/finfocus/cost-drift"><img src="https://agentmods.dev/badge/skills/rshade/finfocus/cost-drift/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.

agentmods 80×15 button for cost-drift

Your own site · 80×15
<a href="https://agentmods.dev/skills/rshade/finfocus/cost-drift"><img src="https://agentmods.dev/badge/skills/rshade/finfocus/cost-drift.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 134 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,547 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00134 $0.01547
Opus 5.5 $0.00054 $0.00619
Sonnet 5.5 $0.00027 $0.00309
Haiku 4.5 $0.00013 $0.00155

Measured 3d ago against content hash e42d8bb17912, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

cost-drift 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 3d 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.

agent-skills/cost-drift/SKILL.md · 150 lines

How it starts

The opening of the file, as written. The whole thing — 150 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Cost Drift

Run finfocus overview on a Pulumi stack, flag resources whose actual spend has moved away from the projection, and write COST_DRIFT.md.

Install: npx skills add rshade/finfocus -s cost-drift.

Required CLI: finfocus v0.5.0 or newer. Update this line with the release the skill was last run against.

Core principle: use the drift the CLI computes. Do not query billing APIs, and do not turn a missing costDrift into "no drift".

overview accepts Terraform plan and state JSON. For a Terraform project, run the cost-check skill and say that drift is not available. Edit this paragraph when that changes.

1. Detect the project

Look for Pulumi.yaml or Pulumi.yml in this directory or a parent. If there is none, stop: "No Pulumi project detected."

2. Preflight

command -v finfocus
finfocus --version
finfocus plugin list --output json
  • No binary: stop and point to the finfocus-install skill.
  • Version below the required one: stop and print both versions. A build such as v0.5.0-6-g3cb7ded counts as v0.5.0. An unparseable version, or 0.1.0 with no leading v (an unstamped source build), continues, and the report says "version unverified".
  • No plugin whose capabilities include actual_costs: stop. Drift needs a plugin that returns billing data. Point to finfocus-install.

Every failure and its handling: references/failure-modes.md.

3. Load thresholds and baseline

Read the drift: section of .cost-check.yml. Absent keys use the defaults: references/thresholds.md. If a previous COST_DRIFT.md exists, keep its drifting-resource count and actual total for the trend.

4. Run the CLI

finfocus overview --output json --yes
finfocus overview --output json --yes --stack <stack> --from 2026-10-01
finfocus overview --output json --yes --state-only

Read the full file on GitHub · 150 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

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.

  1. 3d ago Changed · +14 lines e42d8bb17912
  2. 1mo ago Changed 61cf3dbe3cbe
  3. 1mo ago Changed · +3 lines 52430f91c9fd
  4. 1mo ago First seen · 133 lines · 134 tokens per session scan A 410f2104433c

Subscribe to this mod's changes

cost-drift is a skill published in the GitHub repository rshade/finfocus (11 stars, last pushed yesterday), licensed Apache-2.0. It adds 134 tokens to every session and 1,547 once invoked, about $0.0005 per session on Opus 5.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-10-20.

Related

cost-drift compared with skills from other repositories

cost-drift next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
cost-driftrshade/finfocusSkill11yesterdayApache-2.0A134Claude Code, Codex
recipescostory-io/costory-finops-mcp-skillsSkill415d agoApache-2.0A236Claude Code, Codex
cost-optimizationcamilooscargbaptista/cto-toolkitSkill98mo agoMITA117Claude Code
aws-cost-opsautomateyournetwork/netclawSkill7394d agoApache-2.0A45Claude Code, Codex
eos-cost-analysisaws/tools-for-devops-agentSkill160yesterdayApache-2.0A215Claude Code, Codex
finops-expertpersonamanagmentlayer/pclSkill471mo agoApache-2.0A55Claude Code
gcp-spend-cap-setupshivamsriva31093/gcp-ironcladSkill241mo agoMITA98Claude Code, Codex