semantic-model-builder

semantic-model-builder is a skill for Claude Code, Codex from nimrodfisher/data-analytics-skills. It costs 46 tokens per session (541 once invoked), scanned A, original, MIT.

A documentation builder for a semantic layer, which gives shared definitions to business metrics, data fields, and entities. It can produce YAML definitions for dbt Semantic Layer and similar systems.

In plain words
What is it for?
Use it to define metrics, describe dimensions and entities, and document structured data models.
Why use it?
It reduces confusion when different people use the same metric or data concept with different meanings.

Skill for Claude CodeCodex

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

Good fit Use it to define metrics, describe dimensions and entities, and document structured data models.

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

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 semantic-model-builder

README.md
[![agentmods](https://agentmods.dev/badge/skills/nimrodfisher/data-analytics-skills/semantic-model-builder/github.svg)](https://agentmods.dev/skills/nimrodfisher/data-analytics-skills/semantic-model-builder)
Your own site
<a href="https://agentmods.dev/skills/nimrodfisher/data-analytics-skills/semantic-model-builder"><img src="https://agentmods.dev/badge/skills/nimrodfisher/data-analytics-skills/semantic-model-builder/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 semantic-model-builder

Your own site · 80×15
<a href="https://agentmods.dev/skills/nimrodfisher/data-analytics-skills/semantic-model-builder"><img src="https://agentmods.dev/badge/skills/nimrodfisher/data-analytics-skills/semantic-model-builder.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 541 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.00046 $0.00541
Opus 5.5 $0.00018 $0.00216
Sonnet 5.5 $0.00009 $0.00108
Haiku 4.5 $0.00005 $0.00054

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

Security

Grade A, and why

semantic-model-builder 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 3mo ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/metric_template_generator.py, scripts/model_yaml_validator.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

02-documentation-knowledge/semantic-model-builder/SKILL.md · 33 lines

How it starts

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

When to use

  • A stakeholder asks "how is [metric] calculated?" and no canonical definition exists
  • You're setting up dbt Semantic Layer and need YAML metric/dimension/entity definitions
  • Multiple teams are using different SQL queries for the same metric — you need to codify the one true definition
  • You're building a data catalog entry for a core model and need structured metadata

Process

  1. Identify the object type — decide whether you're documenting a metric, a dimension, or an entity. Use the frameworks in references/metric_definition_framework.md for metrics and references/dimension_hierarchy_patterns.md for dimensions.
  2. Gather the definition inputs — collect: calculation logic (SQL or formula), business context, data source(s), grain, edge cases, and known gotchas. Ask the data owner if anything is unclear.
  3. Generate the YAML template — run scripts/metric_template_generator.py to scaffold the initial YAML structure for the object type. Fill in the generated template.
  4. Validate the YAML — run scripts/model_yaml_validator.py to check required fields, type constraints, and reference integrity (referenced dimensions exist in the same file).
  5. Add dbt context — if this will be deployed to dbt Semantic Layer, consult references/dbt_semantic_layer_guide.md for the exact field names and constraints for your dbt version.
  6. Save final definitions — save metrics to assets/metric_definition.yaml, dimensions to assets/dimension_definition.yaml, entities to assets/entity_definition.yaml.

Inputs the skill needs

  • Required: the metric name or model name to document
  • Required: calculation logic — SQL snippet, formula, or plain-English steps
  • Required: business context — who uses it, what decision it informs, what a "good" value looks like
  • Optional: data source table(s) and column names
  • Optional: target semantic layer framework (dbt Semantic Layer, Cube.js, LookML, etc.)
  • Optional: existing YAML to validate

Output

  • assets/metric_definition.yaml — filled metric YAML definition(s)
  • assets/dimension_definition.yaml — filled dimension YAML definition(s)
  • assets/entity_definition.yaml — filled entity YAML definition(s)
  • Validation report from scripts/model_yaml_validator.py (inline output)

Read the full file on GitHub · 33 lines

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. 3mo ago First seen · 33 lines · 46 tokens per session scan A fd6f95035beb

Subscribe to this mod's changes

semantic-model-builder is a skill published in the GitHub repository nimrodfisher/data-analytics-skills (564 stars, last pushed 23d ago), licensed MIT. It adds 46 tokens to every session and 541 once invoked, about $0.0002 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-08-30.

Related

semantic-model-builder compared with skills from other repositories

semantic-model-builder next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
semantic-model-buildernimrodfisher/data-analytics-skillsSkill56423d agoMITA46Claude Code, Codex
bigquery-migration-metadata-extractorgoogle/skillsSkill25ktodayApache-2.0A188Claude Code, Codex
bigquery-migration-data-exportergoogle/skillsSkill25ktodayApache-2.0A142Claude Code, Codex
alloydb-basicsgoogle/skillsSkill25ktodayApache-2.0A72Claude Code, Codex
cloud-databases-onboardinggoogle/skillsSkill25ktodayApache-2.0A83Claude Code, Codex
obsidian-baseskepano/obsidian-skillsSkill55k4d agoMITA63Claude Code
spanner-basicsgoogle/skillsSkill25ktodayApache-2.0A47Claude Code, Codex