/dqx:dqx-storagefrom dqx
Loads and saves DQX data quality checks to files, Delta tables, Unity Catalog volumes, Lakebase, or workspace paths. Covers all ChecksStorageConfig types and their load/save methods.
Ships in dqx. 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.
DQX persists checks as metadata (list[dict]) — that's the portable form. Use class-form (DQRowRule) in code, then convert via serialize_checks(...) from databricks.labs.dqx.checks_serializer before saving (see dqx-define-checks).
All operations go through DQEngine:
from databricks.labs.dqx.engine import DQEngine
from databricks.sdk import WorkspaceClient
dq = DQEngine(WorkspaceClient())
dq.save_checks(checks_metadata, config=...) # any ChecksStorageConfig below
checks_metadata = dq.load_checks(config=...)
| Config | Location example | When to use |
|---|---|---|
FileChecksStorageConfig | "checks.yml" | Local / repo-relative path. Simplest; also resolves to workspace paths when run from a Databricks notebook or job. |
WorkspaceFileChecksStorageConfig | "/Shared/App1/checks.yml" | Absolute workspace path outside your installation. Good for team-shared rule libraries. |
VolumeFileChecksStorageConfig | "/Volumes/cat/schema/vol/checks.yml" | Unity Catalog volume — versioned, auditable, works across workspaces. |
TableChecksStorageConfig | "catalog.schema.checks" | Most scalable. Schema includes a run_config_name discriminator so multiple pipelines can share one table. |
InstallationChecksStorageConfig | run_config_name="default" | Resolves to whatever checks_location is set in the DQX workspace install's RunConfig. Use this inside workflows so a single config change re-points every pipeline. |
LakebaseChecksStorageConfig | "database.schema.checks" | Store checks in a Lakebase Postgres-compatible catalog. |
import yaml
from databricks.labs.dqx.config import FileChecksStorageConfig, WorkspaceFileChecksStorageConfig
checks = yaml.safe_load("""
- criticality: warn
check:
function: is_not_null_and_not_empty
arguments:
column: col3
- criticality: error
check:
function: is_not_null
for_each_column: [col1, col2]
""")
# Relative / repo path
dq.save_checks(checks, config=FileChecksStorageConfig(location="checks.yml"))
# Absolute workspace path (shared across users)
dq.save_checks(checks, config=WorkspaceFileChecksStorageConfig(location="/Shared/App1/checks.yml"))
from databricks.labs.dqx.config import TableChecksStorageConfig
cfg = TableChecksStorageConfig(
location="catalog.schema.checks",
run_config_name="orders_pipeline", # partition key — one row per (rule, run_config)
mode="overwrite", # or "append"
)
dq.save_checks(checks, config=cfg)
loaded = dq.load_checks(config=cfg)
See Table Schemas and Relationships for the table schema.
When DQX is installed in a workspace (databricks labs dqx install), every RunConfig in .dqx/config.yml has a checks_location field. Use InstallationChecksStorageConfig so notebooks, workflows, and ad-hoc code all resolve to the same place:
from databricks.labs.dqx.config import InstallationChecksStorageConfig
cfg = InstallationChecksStorageConfig(run_config_name="default")
checks = dq.load_checks(config=cfg)
databricks labs dqx open-remote-config # open the config file in the UI
databricks labs dqx profile --run-config default --patterns "main.product001.*" # generate + save via the profiler workflow
InstallationChecksStorageConfig from workflows; it makes the pipeline portable across workspaces.TIME TRAVEL gives you that for free; if you're on YAML in a repo, use git.DQRowRule) directly — call serialize_checks(...) from databricks.labs.dqx.checks_serializer first.FileChecksStorageConfig with a relative path inside a Databricks job cluster unless you understand where that resolves — prefer WorkspaceFileChecksStorageConfig or a volume.Canonical docs: https://databrickslabs.github.io/dqx/docs/guide/quality_checks_storage.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub databrickslabs/dqx --plugin dqx5 skills in this plugin
/dqx-apply-checksValidate a PySpark DataFrame or Delta table against a set of DQX quality rules using DQEngine. Use when the user asks to "run data quality checks", "apply DQX rules to a DataFrame/table", "split valid and invalid rows", "quarantine bad records", or "integrate DQX into a streaming pipeline". Covers apply_checks, apply_checks_and_split, the by_metadata variants, and the shape of the result columns.
/dqx-define-checksCreate DQX quality rules (checks) for a PySpark DataFrame or Delta table. Use when the user asks to "add a DQX check", "define a data quality rule", "validate that column X is not null / unique / in a set", or wants checks expressed in YAML/JSON for storage. Covers DQRowRule, DQDatasetRule, DQForEachColRule, built-in check_funcs, filters, user_metadata, custom SQL/Python checks, and the declarative metadata form.
/dqx-end-to-endRun DQX validation end-to-end — read an input table or path, apply checks, and write valid and quarantined rows to output locations — in a single call. Use when the user asks for "apply and save", "quality-check a table and split the output", "DQX on a whole table", "save valid and invalid rows", or wants to drop DQX into a Lakeflow / workflow that runs on a table or path. Covers apply_checks_and_save_in_table, the by_metadata variant, InputConfig / OutputConfig, and incremental streaming mode.
/dqx-profile-and-generateProfile a DataFrame or table and generate DQX quality rule candidates with summary statistics. Use when the user asks to "profile a table", "generate DQX rules from data", "suggest data quality checks", "bootstrap a checks.yml", or "generate DLT expectations". Covers DQProfiler, DQGenerator, DQDltGenerator, the profiler workflow, sampling / filter options, and AI-assisted variants.
Other plugins' skills for the same job