/wire:dagsterfrom wire
Guides building Dagster orchestration layers with assets-first patterns, dagster-dbt integration, automation (schedules, sensors, declarative automation), component framework, and CLI usage (dg dev, dg launch, dg check, dg scaffold). Activates when creating or modifying Dagster assets, schedules, sensors, or components.
Ships in wire. 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.
Before proceeding, append a one-line entry to .wire/execution_log.md:
| YYYY-MM-DD HH:MMZ | skill | dagster | Dagster orchestration work triggered this skill | <by> | <session> | n/a | n/a | n/a |
If .wire/execution_log.md does not exist, create it with the standard header first (see specs/utils/execution_log.md). If no .wire/ directory exists in the current repo, skip this step.
This skill activates when working with Dagster to ensure correct patterns, avoid common anti-patterns, and produce production-quality orchestration code. It is tailored for Wire projects where Dagster orchestrates dbt-based data pipelines.
dagster-dbt)dg dev, dg launch, dg check, dg scaffold)Keywords: "dagster", "dg dev", "dg launch", "@asset", "@multi_asset", "materialize", "MaterializeResult", "dagster-dbt", "DbtProjectComponent", "ScheduleDefinition", "SensorDefinition", "AutomationCondition", "dg scaffold", "software-defined assets", "asset graph"
Activate before generating any Dagster code when:
dagster.yaml, dagster_orchestration/, or imports of dagster in Python filesorchestration_tool: dagsterAlways use the @dg.asset decorator. Prefer the dg. namespace prefix:
import dagster as dg
@dg.asset(
group_name="ingestion",
description="Brief description of what this asset produces",
compute_kind="python", # or "dbt", "sql", "spark"
tags={"layer": "ingestion", "source": "salesforce"},
)
def salesforce_contacts(context: dg.AssetExecutionContext) -> dg.MaterializeResult:
context.log.info("Running salesforce_contacts ingestion")
# ... logic ...
return dg.MaterializeResult(
metadata={"row_count": dg.MetadataValue.int(rows_written)}
)
Anti-patterns to avoid:
@asset without dg. prefix (old style)SkipReason in sensors, MaterializeResult with metadata in assetsprint() instead of context.log.info()EnvVar in resources@dg.multi_asset(
specs=[
dg.AssetSpec("orders_raw", group_name="ingestion"),
dg.AssetSpec("order_items_raw", group_name="ingestion"),
],
compute_kind="python",
)
def ingest_orders(context: dg.AssetExecutionContext):
context.log.info("Ingesting orders and order_items together")
# ... logic ...
yield dg.Output(value=None, output_name="orders_raw")
yield dg.Output(value=None, output_name="order_items_raw")
Use when a single API call or database query naturally produces multiple related tables.
Always use the DbtProjectComponent YAML configuration approach in new projects:
components/dbt_project.yaml:
type: dagster_dbt.DbtProjectComponent
params:
dbt_project_dir: ../../ # path to directory containing dbt_project.yml
select: "*"
exclude: ""
This automatically generates one Dagster asset per dbt model, maintaining the dbt dependency graph. Dagster resolves ref() calls as asset dependencies.
For more control, use @dbt_assets directly:
from dagster_dbt import DbtProject, dbt_assets
dbt_project = DbtProject(project_dir=Path(__file__).parent.parent.parent)
@dbt_assets(manifest=dbt_project.manifest_path)
def dbt_models(context: dg.AssetExecutionContext, dbt: DbtCliResource):
yield from dbt.cli(["run"], context=context).stream()
Asset key convention: Dagster-dbt creates keys as AssetKey(["<model_name>"]). To set a custom key prefix (e.g., matching a schema): use key_prefix in @dbt_assets or DbtProjectComponent.asset_attributes.
from dagster import ScheduleDefinition, define_asset_job, AssetSelection
daily_refresh_job = define_asset_job(
name="daily_refresh",
selection=AssetSelection.all(),
)
daily_schedule = ScheduleDefinition(
name="daily_refresh_schedule",
cron_schedule="0 3 * * *", # 3am UTC daily
job=daily_refresh_job,
execution_timezone="UTC",
default_status=dg.DefaultScheduleStatus.RUNNING,
)
Cron reference (common patterns):
| Expression | Meaning |
|---|---|
0 * * * * | Every hour |
0 3 * * * | Daily at 3am UTC |
0 3 * * 1 | Weekly Monday 3am UTC |
0 3 1 * * | Monthly 1st at 3am UTC |
*/15 * * * * | Every 15 minutes |
Use when pipeline should trigger on an event (upstream asset materialization, file arrival):
@dg.asset_sensor(
asset_key=dg.AssetKey("source_asset_name"),
job=downstream_job,
minimum_interval_seconds=60,
)
def source_ready_sensor(
context: dg.SensorEvaluationContext,
asset_event: dg.EventLogEntry,
):
yield dg.RunRequest(run_key=context.cursor)
Prefer AutomationCondition over explicit sensors for standard scheduling patterns:
@dg.asset(
automation_condition=dg.AutomationCondition.eager(), # run as soon as upstream is ready
)
def downstream_asset(): ...
@dg.asset(
automation_condition=dg.AutomationCondition.on_cron("0 3 * * *"), # daily at 3am
)
def daily_asset(): ...
Use eager() for streaming/event-driven pipelines. Use on_cron() for batch pipelines.
@dg.resource
def bigquery_resource(context):
return bigquery.Client(project=dg.EnvVar("GCP_PROJECT_ID").get_value())
Always inject credentials via EnvVar, never hardcode. Use {{ env.VAR_NAME }} in YAML component configs.
| Command | Purpose |
|---|---|
uvx create-dagster project <name> | Scaffold new project — NEVER create manually |
dg dev | Start local Dagster UI at localhost:3000 |
dg launch --assets "*" | Materialize all assets |
dg launch --assets "group:ingestion" | Materialize assets in group |
dg launch --assets "tag:layer=ingestion" | Materialize assets by tag |
dg check defs | Validate definitions load without errors |
dg list defs | List all registered assets, schedules, sensors |
dg list defs --select "kind:dbt" | List dbt assets only |
dg scaffold defs AssetSpec | Add a new asset definition |
Always register everything in __init__.py:
import dagster as dg
from . import assets, schedules
defs = dg.Definitions(
assets=dg.load_assets_from_modules([assets]),
schedules=[schedules.daily_schedule],
sensors=[],
resources={},
)
load_assets_from_modules() automatically discovers all @dg.asset and @dg.multi_asset decorated functions in the module.
In Wire projects, dbt models follow the naming convention: stg_<source>__<entity>, int_<group>__<entity>, wh_<group>__<entity>_dim/wh_<group>__<entity>_fact. Dagster-dbt exposes these as asset keys — use these keys when creating downstream assets:
@dg.asset(deps=[dg.AssetKey("wh_sales__order_fact")])
def orders_report(): ...
Use groups to mirror Wire's dbt layering:
| Group name | Contents |
|---|---|
ingestion | Source system assets (raw data landing) |
staging | Maps to dbt staging layer |
integration | Maps to dbt integration layer |
warehouse | Maps to dbt warehouse layer |
reporting | BI / semantic layer downstream assets |
Standard env vars for Wire + Dagster projects:
ANTHROPIC_API_KEY= # for Wire commands
DBT_PROFILES_DIR= # path to dbt profiles.yml
DAGSTER_HOME=~/.dagster # Dagster storage directory
<SOURCE>_API_KEY= # per source system
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
dagster, data-orchestration, dagster-dbt, assets-first, data-pipelines
npx claudepluginhub rittmananalytics/wire-plugin --plugin wire74 skills in this plugin
/add-analytics-instrumentationEnd-to-end analytics instrumentation workflow for a PR, branch, file, directory, or feature. Reads the code, discovers what events should be tracked, and produces a concrete instrumentation plan — all in one shot. Use this skill whenever a user wants to add analytics to a PR, asks "instrument this PR", "add tracking to this branch", "what analytics does this file need", "instrument the checkout flow", "run the full instrumentation workflow", or any request that implies going from code changes to a tracking plan. Also trigger when the user gives you a PR link, branch name, file path, or feature description and mentions analytics, events, or instrumentation. This is the main entry point for the analytics workflow — prefer it over calling the individual steps (diff-intake, discover-event-surfaces, instrument-events) separately.
/agents-schemaPublish and read warehouse metadata through dbt Labs' Agents Schema (the AGENTS schema inside Snowflake, Databricks or BigQuery, written by the agents-schema CLI from a dbt manifest, LookML, Omni, OSI, Sigma and markdown skills). Activates when the user mentions Agents Schema, agents_schema, AGENTS.ROOT, the agents-schema CLI or its GitHub workflows, warehouse-delivered skills, or asks how an AI agent should find governed context for a warehouse. Used by /wire:agents_schema-generate, -validate and -review, and for ad-hoc work against an AGENTS schema./airbyteSkill for managing Airbyte connections and data ingestion via the Airbyte Agent MCP server at mcp.airbyte.ai. Activates when the user mentions Airbyte, an Airbyte connection, Airbyte source / destination, or wants to audit / build / migrate an Airbyte deployment. Distinguishes between the hosted Agent MCP (for AI agents using connectors) and managing an existing Airbyte Cloud / OSS workspace./airflowProactive skill for Apache Airflow 2.x and Cloud Composer work in a client's existing Airflow repo. Auto-activates when writing or changing a DAG file, a DAG helper, or the config a DAG reads; when deploying DAG files to a dev environment; when checking whether a DAG parsed or a run succeeded; when tasks are stuck in queued; and when the pipeline or orchestration artifact uses Airflow. Covers the Airflow rule set (lint_conventions.py --domain airflow), safe dev deploy through airflow_deploy.py, sync and parse checks, run and task checks through Cloud Logging, causes of queued tasks and a list of known faults. Every environment value comes from .wire/engagement/airflow_environments.yml./analyze-account-healthSummarizes B2B account health by analyzing usage patterns, engagement trends, risk signals, and expansion opportunities. Use for customer success reviews, renewal preparation, QBRs, or account prioritization./analyze-ai-topicsAnalyzes what users ask AI agents about and how well each topic is served. Only use when the user has Amplitude Agent Analytics instrumented in their project. Use when the user asks "what are people asking the AI", "top AI topics", "where is the AI struggling", "AI coverage gaps", "what should we improve in our AI", or wants product insights from AI conversation patterns.
Other plugins' skills for the same job