Code Implementation
apache/shardingsphere
Implement, fix, refactor, or remove repository code under required scope, non-regression, verification, and review gates.
A skill your agent uses when creating, editing, reviewing, or troubleshooting Bruin semantic layer models, semantic query CLI usage, metric and dimension definitions, joins, segments, filters…
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install bruin-data/bruin bruin-semantic-layer --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/bruin-semantic-layer .claude/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .claude/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layerType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install bruin-data/bruin bruin-semantic-layer --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/bruin-semantic-layer .agents/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .agents/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install bruin-data/bruin bruin-semantic-layer --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/bruin-semantic-layer .cursor/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .cursor/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/bruin-data/bruin.git --path skills/bruin-semantic-layer--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install bruin-data/bruin bruin-semantic-layer --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/bruin-semantic-layer .gemini/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .gemini/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install bruin-data/bruin bruin-semantic-layerInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/bruin-semantic-layer .github/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .github/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add bruin-data/bruin --skill bruin-semantic-layer -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install bruin-data/bruin bruin-semantic-layer --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/bruin-data/bruin.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/bruin-semantic-layer .opencode/skills/bruin-semantic-layer && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "bruin-semantic-layer" agent skill from https://github.com/bruin-data/bruin/tree/main/skills/bruin-semantic-layer into .opencode/skills/bruin-semantic-layer/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "bruin-semantic-layer", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
bruin-semantic-layerA skill your agent uses when creating, editing, reviewing, or troubleshooting Bruin semantic layer models, semantic query CLI usage, metric and dimension definitions, joins, segments, filters…
Bruin Semantic Layer is an agent skill from bruin-data/bruin. Use when creating, editing, reviewing, or troubleshooting Bruin semantic layer models, semantic query CLI usage, metric and dimension definitions, joins, segments, filters, windows, semantic quality checks, or semantic-layer tests and docs in a Bruin repository.
Its SKILL.md is about 2.6k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
It sits in Databases. It works with SQL. The repository describes itself as: Build data pipelines with SQL and Python, ingest data from different sources, add quality checks, and build end-to-end flows. The licence is Apache-2.0.
5 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit c2ab5b5. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are bash and yaml).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Bruin Semantic Layer loads about 2.6k tokens when it runs. Until then it costs about 71 tokens; SKILL.md has 1,060 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from bruin-data/bruin at commit c2ab5b5, republished under its Apache-2.0 licence (© bruin-data). 1,060 words, ~2,619 tokens.
.claude/skills/bruin-semantic-layer/SKILL.md (or your agent's skills folder).semantic/ before editing. Bruin loads every .yml and .yaml model under the repository-level semantic/ directory next to .bruin.yml.docs/core-concepts/semantic-layer.md, docs/commands/query.md, docs/commands/semantic.md, semantic-engine/model.go, semantic-engine/engine.go, semantic-engine/graph.go, and semantic-engine/checks.go.schema: v1, although omitted schema defaults to v1.bruin semantic validate, run bruin semantic check when a connection is available, then run the repository-required final checks before finishing.Create or edit files under semantic/:
schema: v1
name: orders
label: Orders
description: Revenue and order metrics
source:
table: analytics.orders
connection: warehouse
primary_key: order_id
joins:
- name: customers
relationship: many_to_one
foreign_key: customer_id
dimensions:
- name: order_id
type: string
checks:
- name: not_null
- name: unique
- name: amount
type: number
- name: order_date
type: time
expression: created_at
granularities:
day: date_trunc('day', created_at)
month: date_trunc('month', created_at)
- name: country
type: string
checks:
- name: not_null
- name: accepted_values
value: [US, DE]
- name: is_first_order
type: boolean
expression: customer_order_number = 1
metrics:
- name: revenue
expression: sum(amount)
format:
type: currency
currency: USD
decimals: 2
checks:
- name: positive
- name: order_count
expression: count(distinct order_id)
- name: avg_order_value
expression: "{revenue} / {order_count}"
- name: completed_revenue
expression: sum(amount)
filter: "status = 'completed'"
- name: running_revenue
expression: "{revenue}"
window:
type: running_total
order_by: order_date
partition_by:
- country
segments:
- name: completed
filter: "status = 'completed'"
checks:
- name: completed_revenue_matches_finance
query:
metrics: [revenue]
segments: [completed]
value: 730
- name: no_negative_amounts
query:
dimensions: [order_id]
filters:
- dimension: amount
operator: lt
value: 0
count: 0source.table is required and can be a relation name or a parenthesized SQL subquery with an alias.source.connection is optional. bruin semantic validate, bruin semantic check, and bruin query --pipeline use it when --connection is not passed.label, description, group, hidden, and format metadata help consumers but do not change SQL generation.expression defaults to the dimension name.type can be string, number, boolean, or time; only time dimensions can use granularities.name:granularity, for example order_date:month.hidden: true hides a dimension from UI-style consumers but does not make it unqueryable.sum(amount) or count(distinct order_id).{metric_name} references. References must resolve and cannot form cycles.NULLIF(..., 0) during SQL generation.filter wraps the metric aggregation. For example, sum(amount) with a filter becomes a conditional aggregate.{refs} for simple queries, but do not put that mixed metric in a window metric dependency chain.number, currency, percentage, and decimal.Window metrics calculate after an inner grouped query and must use expression: "{base_metric}".
window.type values: running_total, lag, lead, rank, and percent_of_total.running_total, lag, lead, and rank require window.order_by referencing a dimension.lag and lead default offset to 1 when omitted or set to zero.partition_by entries must reference dimensions.percent_of_total does not require order_by; it can use partition_by.checks, because they return one row per order_by group. Use a model check instead.--segment.dimension, operator, and optional value.equals, not_equals, gt, gte, lt, lte, in, not_in, between, is_null, is_not_null.between accepts a two-item array or an object with start and end.expression; use this sparingly because it bypasses structured validation.HAVING; dimension-only filters compile into WHERE.name is the relation prefix used in queries, such as customers.country.model is omitted, Bruin uses the join name as the target model name.one_to_one, many_to_one, one_to_many, and many_to_many.one_to_one and many_to_one are automatically traversed in semantic queries because they avoid fanout.foreign_key or custom sql.foreign_key joins, Bruin joins the current model's foreign_key to the target model's target_key; if target_key is omitted, the target model must define primary_key.{orders}, {customers}, or the join name placeholder.dimensions[].checks) work like column checks: not_null, unique, positive, non_negative, negative, min, max, accepted_values, and pattern. They test every row of the model source, and all of them except not_null ignore nulls.metrics[].checks) test the metric computed over the whole model: not_null, positive, non_negative, negative, min, max, and equals. A null metric fails every metric check.checks) need a unique name and a query. The query is a semantic query with dimensions, metrics, filters, segments, sort, and limit, and accepts the name:granularity and name:direction shorthands. There is no raw SQL option.count: 0. To find unmatched join rows, filter on a null joined dimension.value or count, never both. count wraps the query in SELECT count(*). value can be:sort. Without value or count, the check expects 0.min, max, and equals require a value, accepted_values requires a non-empty list, and pattern requires a string. Other checks reject a value. A check name can appear only once per dimension or metric.bruin semantic validate validates definitions, and dry-runs the compiled SQL when it finds a connection (--connection, then source.connection). A model without a usable connection only gets structural validation and a warning.bruin semantic check runs the checks and exits non-zero on any failure. Use --model to limit it to specific models and --output json for machine-readable results.Use an anchor SQL asset when Bruin should infer the pipeline, connection, and dialect:
bruin query \
--asset ./pipelines/daily-orders/assets/orders.sql \
--semantic-model orders \
--dimension order_date:month \
--metric revenue \
--filter '{"dimension":"country","operator":"equals","value":"US"}' \
--segment completed \
--sort revenue:desc \
--output jsonUse a pipeline path when there is no anchor asset. Pass the connection explicitly, or leave out --connection if the model sets source.connection:
bruin query \
--pipeline ./pipelines/daily-orders \
--connection warehouse \
--semantic-model orders \
--dimension customers.country \
--metric revenue \
--sort customers.country:ascSemantic query mode requires at least one dimension or metric and cannot be combined with --query. Sort direction defaults to asc; --limit applies only when greater than zero.
name and source.table.name, metric name and expression, segment name and filter.expression: "{revenue}".order_by and partition_by values must reference dimensions on the model.For behavior changes, update the implementation, tests, and user-facing docs together: semantic-engine/, pkg/semanticcheck/, cmd/semantic.go, docs/core-concepts/semantic-layer.md, docs/commands/query.md, and docs/commands/semantic.md.
© bruin-data, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/bruin-semantic-layer of bruin-data/bruin.
Open the folder on GitHubat commit c2ab5b5
Bruin Semantic Layer next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Bruin Semantic Layer this skillbruin-data/bruin | 1.8k | — | ~2.6k | Automated safety check: Pass | Apache-2.0 | |
| Code Implementationapache/shardingsphere | 21k | — | ~1.2k | Automated safety check: Pass | Apache-2.0 | |
| Analyzing Dataastronomer/agents | 451 | — | ~1.3k | Automated safety check: Pass | Apache-2.0 | |
| Basincloudflare/skills | 3k | 1 repos | ~684 | Automated safety check: Pass | Apache-2.0 | |
| VisualizationFrankChen021/datastoria | 327 | — | ~1.2k | Automated safety check: Pass | Custom licence | |
| Databricks Dbsqldatabricks/databricks-agent-skills | 345 | 1 repos | ~2.8k | Automated safety check: Pass | Custom licence |
apache/shardingsphere
Implement, fix, refactor, or remove repository code under required scope, non-regression, verification, and review gates.
astronomer/agents
Queries the data warehouse with SQL and answers business questions about data.
cloudflare/skills
Build and troubleshoot Cloudflare Basin analytics workflows with Basin Pipelines, Basin Catalog, and Basin SQL.
FrankChen021/datastoria
Rules for charts and visualization. An agent skill from FrankChen021/datastoria.
databricks/databricks-agent-skills
Databricks SQL (DBSQL) advanced features and SQL warehouse capabilities.
rocky-data/rocky
Rocky DSL (.rocky file) cross-subproject cascade. An agent skill from rocky-data/rocky.
bruin-data/bruin
Create, update, render, and visually verify polished Bruin CLI terminal demos with VHS.
bruin-data/bruin
Add Bruin CLI support for a new ingestr source. An agent skill from bruin-data/bruin.
bruin-data/bruin
Create DAC dashboards by writing YAML or TSX dashboard definition files.
bruin-data/bruin
A skill your agent uses when duplicate rows, unstable primary keys, repeated ingestion, or failed uniqueness checks appear in a Bruin asset.
bruin-data/bruin
A skill your agent uses when a Bruin pipeline, asset, or command fails and the cause is not yet clear.
bruin-data/bruin
A skill your agent uses when a pipeline fails because source, destination, or declared asset columns may have changed.
Works with
Categories
A skill your agent uses when creating, editing, reviewing, or troubleshooting Bruin semantic layer models, semantic query CLI usage, metric and dimension definitions, joins, segments, filters…. Bruin Semantic Layer is an agent skill from bruin-data/bruin. Use when creating, editing, reviewing, or troubleshooting Bruin semantic layer models, semantic query CLI usage, metric and dimension definitions, joins, segments, filters, windows, semantic quality checks, or semantic-layer tests and docs in a Bruin repository.
Bruin Semantic Layer fits situations like: troubleshooting Bruin semantic layer models; semantic query CLI usage; metric and dimension definitions; semantic quality checks.
Run `npx skills add bruin-data/bruin --skill bruin-semantic-layer -a claude-code`. Or copy the skill folder (skills/bruin-semantic-layer in bruin-data/bruin) into .claude/skills/bruin-semantic-layer in your project. Claude Code loads it when a task matches its description.
Run `npx skills add bruin-data/bruin --skill bruin-semantic-layer -a codex`. Or copy the skill folder (skills/bruin-semantic-layer in bruin-data/bruin) into .agents/skills/bruin-semantic-layer in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add bruin-data/bruin --skill bruin-semantic-layer -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/bruin-semantic-layer, .gemini/skills/bruin-semantic-layer, .github/skills/bruin-semantic-layer and .opencode/skills/bruin-semantic-layer in your project.
SKILL.md names no scripts, command-line tools or credentials: Bruin Semantic Layer is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Bruin Semantic Layer is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.6k tokens (SKILL.md is roughly 10k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Bruin Semantic Layer: Code Implementation (apache/shardingsphere, 21k stars), Analyzing Data (astronomer/agents, 451 stars), Basin (cloudflare/skills, 3k stars) and Visualization (FrankChen021/datastoria, 327 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
bruin-data (a GitHub organization) maintains it in bruin-data/bruin, which has 1,771 GitHub stars. The repository holds 10 skills in this directory. The repository was last updated on October 7, 2026.
Source: bruin-data/bruin on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.