skills/dimensional-modeler/SKILL.md
Star schema, snowflake schema, SCD types, and Kimball methodology for analytical data modeling. Activate on: dimensional model, star schema, snowflake schema, SCD, fact table, dimension table, Kimball, grain, surrogate key. NOT for: dbt implementation (use dbt-analytics-engineer), warehouse tuning (use data-warehouse-optimizer).
npx skillsauth add curiositech/windags-skills dimensional-modelerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Design analytical data models using Kimball methodology with star schemas, slowly changing dimensions, and proper grain definition.
Activate on: "dimensional model", "star schema", "snowflake schema", "SCD", "fact table", "dimension table", "Kimball", "grain", "surrogate key", "conformed dimension", "bridge table"
NOT for: dbt SQL implementation → dbt-analytics-engineer | Warehouse performance tuning → data-warehouse-optimizer | OLTP schema design → relevant backend skill
| Domain | Technologies | |--------|-------------| | Methodology | Kimball, Inmon (Data Vault for staging) | | Schema Types | Star schema, snowflake schema, galaxy schema | | SCD | Type 0 (fixed), Type 1 (overwrite), Type 2 (versioned), Type 3 (column) | | Fact Types | Transaction, periodic snapshot, accumulating snapshot, factless | | Implementation | dbt, SQL DDL, modeling tools (dbtERD, dbdiagram.io) |
┌──────────────┐
│ dim_date │
│──────────────│
│ date_key (PK)│
│ full_date │
│ year, quarter│
│ month, week │
│ is_holiday │
└──────┬───────┘
│
┌──────────────┐ ┌──────┴───────┐ ┌──────────────┐
│ dim_customer │ │ fct_orders │ │ dim_product │
│──────────────│ │──────────────│ │──────────────│
│ customer_key │←───│ customer_key │───→│ product_key │
│ customer_id │ │ product_key │ │ product_id │
│ name │ │ date_key │ │ name │
│ segment │ │ store_key │ │ category │
│ region │ │──────────────│ │ brand │
└──────────────┘ │ quantity │ └──────────────┘
│ unit_price │
│ discount_amt │ ┌──────────────┐
│ total_amount │ │ dim_store │
└──────┬───────┘ │──────────────│
│ │ store_key │
└───────────→│ store_name │
│ city, state │
└──────────────┘
Grain: one row per order line item
Facts: quantity, unit_price, discount_amt, total_amount
-- dim_customer with SCD Type 2 (track history)
CREATE TABLE dim_customer (
customer_key BIGINT PRIMARY KEY, -- surrogate key (auto-increment)
customer_id VARCHAR(50), -- natural/business key
name VARCHAR(200),
email VARCHAR(200),
segment VARCHAR(50),
region VARCHAR(50),
-- SCD Type 2 metadata
effective_from TIMESTAMP NOT NULL,
effective_to TIMESTAMP DEFAULT '9999-12-31',
is_current BOOLEAN DEFAULT TRUE
);
-- Merge pattern: close old record, insert new
-- When customer changes segment:
UPDATE dim_customer
SET effective_to = CURRENT_TIMESTAMP, is_current = FALSE
WHERE customer_id = 'CUST-123' AND is_current = TRUE;
INSERT INTO dim_customer (customer_id, name, email, segment, region,
effective_from, is_current)
VALUES ('CUST-123', 'Jane Doe', '[email protected]', 'Enterprise', 'West',
CURRENT_TIMESTAMP, TRUE);
-- Query: joins always use surrogate key + is_current for latest
-- Historical analysis: join on surrogate key with date range overlap
Transaction Fact Periodic Snapshot Accumulating Snapshot
───────────────── ───────────────── ─────────────────────
One row per event One row per period One row per lifecycle
Example: fct_orders Example: fct_daily_ Example: fct_order_
inventory fulfillment
Grain: order line item Grain: product x day Grain: one order
Measures: amount, qty Measures: qty_on_hand, Measures: order_date,
qty_sold, qty_ordered ship_date, deliver_date
Grows: continuously Grows: daily/weekly Updates: as lifecycle
stages complete
fct_ for facts, dim_ for dimensionstools
Building resilient distributed systems with circuit breakers, retries with full-jitter exponential backoff, retry budgets (per-request 3-attempt + per-client 10% ratio per Google SRE), deadline propagation, and the cascading-failure math (4 layers × 3 retries = 64x amplification). Grounded in Resilience4j, Microsoft Cloud Patterns, AWS Architecture Blog (Marc Brooker), and Google SRE Book.
testing
Designing HTTP cache headers that work correctly across browsers, CDNs, and shared proxies — `Cache-Control` directives per RFC 9111, `stale-while-revalidate` and `stale-if-error` per RFC 5861, the Vary header for varying responses, and surrogate keys for tag-based purging. Grounded in IETF RFCs and Cloudflare/Fastly docs.
development
Use when designing or fixing a Content Security Policy on a real site, choosing between nonce-based and hash-based CSP, adding strict-dynamic, debugging "Refused to execute inline script" errors, deploying CSP in report-only mode first, configuring report-to / report-uri, or auditing an existing policy for unsafe-inline / unsafe-eval / wildcards. Triggers: "CSP blocks legitimate inline script", strict-dynamic, nonce-{RANDOM}, sha256-{HASH}, object-src none, base-uri none, frame-ancestors, Trusted Types, X-Content-Security-Policy obsolete, report-only vs enforced. NOT for general HTTP security headers (HSTS, COOP/COEP), Trusted Types deep dive, CORS configuration, or building a WAF.
tools
Choosing and operating an HTTP API versioning strategy that doesn't break clients — Stripe's date-based pinned versions, the Deprecation/Sunset header pair (RFC 9745 + RFC 8594), URI vs header vs media-type approaches, and the version-transformer pattern. Grounded in Stripe's published architecture and IETF RFCs.