data-model-design

data-model-design is a skill for Claude Code from hollandkevint/data-product-operator. It costs 80 tokens per session (827 once invoked), scanned A, original, MIT.

A guide to designing database structures for analytics products, including fact tables for events and dimension tables for descriptive context. It covers star schemas, denormalization choices, history tracking, and written architecture decisions.

In plain words
What is it for?
Use it to design or review tables, relationships, naming, normalization choices, and historical data handling for reporting and analytics.
Why use it?
It helps prevent schemas that are difficult to query, produce duplicated results, or lose important history. It starts from the questions users need answered so the structure supports real analysis.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Part of the data-product-operator plugin — 17 skills, 7 commands, 1 MCP server shipped together

Good fit Use it to design or review tables, relationships, naming, normalization choices, and historical data handling for reporting and analytics.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hollandkevint/data-product-operator/data-model-design
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 hollandkevint/data-product-operator --skill data-model-design
Clone the repo
git clone --depth 1 https://github.com/hollandkevint/data-product-operator

Made for: Claude Code.

Or install data-product-operator, the plugin that ships this one along with the rest of its 17 skills, 7 commands, 1 MCP server.

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 data-model-design

README.md
[![agentmods](https://agentmods.dev/badge/skills/hollandkevint/data-product-operator/data-model-design.svg)](https://agentmods.dev/skills/hollandkevint/data-product-operator/data-model-design)
Your own site
<a href="https://agentmods.dev/skills/hollandkevint/data-product-operator/data-model-design"><img src="https://agentmods.dev/badge/skills/hollandkevint/data-product-operator/data-model-design.svg" alt="Measured on agentmods" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 827 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.00080 $0.00827
Opus 5 $0.00040 $0.00413
Sonnet 5 $0.00016 $0.00165
Haiku 4.5 $0.00008 $0.00083

Measured 7d ago against content hash 2a502892fe21, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

data-model-design 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 7d 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.

skills/data-model-design/SKILL.md · 79 lines

How it starts

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

Star Schema as Default

For analytics data products, default to star schema with strategic denormalization:

Fact tables contain events at the lowest useful grain:

  • One row per event (transaction, visit, measurement, interaction)
  • Foreign keys to dimension tables
  • Numeric measures (amount, count, duration)
  • Timestamps at the grain of the analysis

Dimension tables contain context:

  • Descriptive attributes for filtering and grouping
  • Human-readable labels alongside codes
  • Hierarchies for drill-down (region -> state -> city)

NEVER fully denormalize into One Big Table. Many-to-many relationships cause exponential row growth. A patient with 10 conditions and 5 medications creates 50 rows instead of 15.

ALWAYS start with the query patterns. What questions will consumers ask? Design the schema to make those queries simple. If 80% of queries filter by date and group by category, those should be the primary dimensions.

Slowly Changing Dimensions (SCD)

Type 1 - Overwrite the old value. Use when history doesn't matter (correcting a typo in a name).

Type 2 - Add a new row with effective dates. Use when you need to track what was true at a point in time (patient address at time of visit, product price at time of sale). Add effective_start_date, effective_end_date, and is_current flag.

Type 3 - Add a column for the previous value. Use when you only need one level of history (current_category, previous_category).

Default to Type 2 for any dimension where the business asks "what was it at the time of X?" Start with Type 1 for everything else and upgrade when the need emerges.

Architecture Decision Records

For every non-obvious modeling decision, write a lightweight ADR:

  • Context: What situation prompted the decision?
  • Options: What alternatives were considered?
  • Decision: What was chosen and why?
  • Consequences: What are the tradeoffs?

Keep ADRs in the repo alongside the schema. Future team members will ask "why is it modeled this way?" The ADR answers before they have to ask.

Read the full file on GitHub · 79 lines

Files

What ships with it

1 file 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. 7d ago First seen · 79 lines · 80 tokens per session scan A 2a502892fe21

Subscribe to this mod's changes

data-model-design is a skill published in the GitHub repository hollandkevint/data-product-operator (3 stars, last pushed 5mo ago), licensed MIT. It adds 80 tokens to every session and 827 once invoked, about $0.0004 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-31.