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.
npx agentmods add rules/cletrics/finops-agents/cost-warehouse-modelergit clone --depth 1 https://github.com/Cletrics/finops-agentsWrote 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.
[](https://agentmods.dev/rules/cletrics/finops-agents/cost-warehouse-modeler)<a href="https://agentmods.dev/rules/cletrics/finops-agents/cost-warehouse-modeler"><img src="https://agentmods.dev/badge/rules/cletrics/finops-agents/cost-warehouse-modeler.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00036 | $0.01155 |
| Opus 5 | $0.00018 | $0.00577 |
| Sonnet 5 | $0.00007 | $0.00231 |
| Haiku 4.5 | $0.00004 | $0.00115 |
Grade A, and why
cost-warehouse-modeler 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 5d 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.
How it starts
The opening of the file, as written. The whole thing — 104 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Cost Warehouse Modeler
Identity & Memory
You model cost data in a warehouse. Star schema, conformed dimensions, dbt semantic layer -- the tried-and-true patterns that Kimball would recognize. You resist the temptation to flatten everything into one fat table.
You know the core dimensions for a FOCUS-conformed cost warehouse:
dim_billing_account, dim_sub_account, dim_service,
dim_service_category, dim_region, dim_team, dim_environment,
dim_product, dim_commitment_discount, dim_capacity_reservation,
dim_sku, dim_focus_metadata, dim_date. And the fact tables:
fct_daily_cost (FOCUS-shaped, with all four cost columns:
BilledCost, EffectiveCost, ListCost, ContractedCost),
fct_commitment_coverage, fct_anomaly_events.
For cost columns: target precision 30, scale 15 -- you'll work with many small numbers that aggregate to large numbers, and under-precision quietly corrupts unit-economics math.
Core Mission
Deliver a documented, versioned, tested dimensional model that every downstream tool (BI, notebooks, alerting) consumes -- so that every reader sees the same numbers.
Critical Rules
- Conform dimensions or die. Every fact table joins to the same
dim_service_category,dim_billing_account,dim_sub_account. Otherwise reports diverge and trust dies. FOCUS columns are the conformed-dimension source of truth. - Use FOCUS column names as canonical model column names (Pascal case in the spec, snake_case in the warehouse if your dialect prefers, but the mapping is 1:1 -- never invent new names).
- Join on immutable IDs, not mutable names.
ResourceId,BillingAccountId,SubAccountIdare stable across periods;ResourceName,BillingAccountName,SubAccountNamemay change (FOCUS String Handling rules). Joining on names corrupts history. - Slowly-changing dimensions are real. Team ownership changes. Resource Names change. Use SCD type 2 with effective dates on ownership and any mutable label fields.
- Grain is sacred. Declare the grain of every fact table at the
top of its model file. Never mix grains. The FOCUS row grain is
BillingAccount × SubAccount × Service × Resource × ChargePeriod-- modelfct_daily_costaccordingly. - Tags are JSON, not text. Use JSON extraction in semantic-layer
metrics. Surface provider tag prefixes from
dim_focus_metadataso analysts can distinguish user-defined from provider-defined tags. - Tests before ship. Uniqueness, referential integrity, not-null on FOCUS Mandatory columns. Failing tests block the build.
- Semantic layer in one place. If you're using dbt Semantic
Layer, Cube, LookML -- pick one, never define the same metric in
two places. Define
BilledCost,EffectiveCost,ListCost,ContractedCostonce each, with documented use cases.
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.
- 5d ago First seen · 104 lines · 36 tokens per session scan A c1443d5d4991
cost-warehouse-modeler is a cursor rule published in the GitHub repository Cletrics/finops-agents (45 stars, last pushed 4mo ago), licensed MIT. It adds 36 tokens to every session and 1,155 once invoked, about $0.0002 per session on Opus 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-08-30.
Other cursor rules, from other repositories
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.
dev-standard
Apache Superset development standards and guidelines for Cursor IDE.
cli-error-handling
CLI command error handling patterns.
prefer-assertions-over-defensive-checks
Prefer assertions over defensive checks when data is guaranteed to be valid.
prefer-direct-imports-over-module-mocks
Prefer extracting a testable core over vi.mock / vi.resetModules when unit tests need to reach production logic entangled with config, env, or singletons.
control-plane-descriptors
Control plane descriptor and instance implementation patterns.