/starlake-skills:starflow-transform-designfrom starlake-skills
Design SQL transformations for data pipelines with quality checks and dependency management. Use when the user says "design transforms" or "create SQL transformations".
Ships in starlake-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Guides the design of SQL transformations that turn raw/curated data into business-ready datasets. Produces Starlake-compatible .sql files and their companion .sl.yml configuration files, including write strategies, sink configuration, and data quality expectations.
Role Guidance: Act as a Data Engineer with expertise in SQL analytics, data modeling, and Starlake's transform engine.
Design Rationale: Transformations are where business logic lives. They must be pure SQL (or Python for complex cases), testable locally on DuckDB, and deployable to any target engine via Starlake's SQL transpiler. Dependencies are inferred from SQL table references.
{planning_artifacts}/data-architecture-*.md{implementation_artifacts}/pipeline-spec-*.md{planning_artifacts}/schema-design-*.mdList all transformations needed:
| Task Name | Source Tables | Target Table | Write Strategy | Schedule |
|---|---|---|---|---|
e.g., orders_daily_agg | sales.orders, ref.products | analytics.orders_daily | OVERWRITE_BY_PARTITION | Daily |
For each transformation, write the SQL:
-- Task: orders_daily_agg
-- Dependencies: sales.orders, ref.products (auto-inferred)
SELECT
DATE(o.order_date) AS order_date,
p.category,
COUNT(*) AS order_count,
SUM(o.amount) AS total_amount,
AVG(o.amount) AS avg_amount
FROM sales.orders o
JOIN ref.products p ON o.product_id = p.product_id
WHERE o.order_date >= CURRENT_DATE - INTERVAL '1 day'
GROUP BY DATE(o.order_date), p.category
Guidelines:
{domain}.{table} notationSL_THIS to reference the current task's output table in expectationsFor each task, create the .sl.yml:
version: 1
transform:
name: "orders_daily_agg"
writeStrategy:
type: "OVERWRITE_BY_PARTITION"
key: ["order_date"]
sink:
partition: ["order_date"]
clustering: ["category"]
connectionRef: "warehouse"
expectations:
- query: "SELECT COUNT(*) > 0 FROM SL_THIS"
name: "not_empty"
failSeverity: "ERROR"
- query: "SELECT COUNT(*) = 0 FROM SL_THIS WHERE total_amount < 0"
name: "no_negative_amounts"
failSeverity: "ERROR"
Document the transformation DAG:
--recursive executionGenerate:
{implementation_artifacts}/transform-design-{{domain}}.md{implementation_artifacts}/transforms/{domain}/transform skill for SQL/Python transformation execution optionsexpectations skill for transform-level data quality checksconfig skill for available SQL functions and type referenceComplete SQL transformations with Starlake task configurations, quality expectations, and a documented dependency graph: ready for implementation and testing.
What SKILL.md sets; muted values are Claude Code's defaults
Generated from the plugin's indexed repository (starlake-ai/starlake-skills) — no native marketplace selected
npx claudepluginhub p/starlake-ai-starlake-skills75 skills in this plugin
/acl-dependenciesVisualize access control with `starlake acl-dependencies` — graph which users and groups can access which tables, from the ACL and RLS (row-level security) definitions in your YAML, output as SVG, PNG, or JSON/autoloadInfer schemas from files in the incoming directory and load them into the warehouse in one step with `starlake autoload`. Use for quick starts or new data files with no YAML table definitions yet; generates the table configs automatically./bootstrapCreate a new Starlake project with `starlake bootstrap` — scaffold the standard metadata/load/transform directory structure and starter config from a template (quickstart, simple). Use when initializing or setting up a new project.