/dak:enforcing-resource-attributionfrom dak
Enforces resource attribution labels on `bq` and `gcloud` commands. Applies mandatory `--label datacloud:<ide>` flags to supported BigQuery operations while avoiding invalid flags on read-only commands.
Ships in dak. 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.
To track resources created or manipulated by AI agents, you MUST ensure that standard CLI commands are tagged with appropriate attribution labels under relevant conditions.
You should apply these attribution labels ONLY under the following conditions:
Do NOT apply these labels if you are running generic administrative commands or working on infrastructure completely unrelated to Data Cloud / Analytics (e.g., managing Compute Engines for web apps, setting up standard IAM policies, etc.).
Do NOT apply --label flags to commands that do not accept labels, as the
--label flag is unsupported by these specific bq subcommands. These include:
bq showbq lsbq versionbq rmbq cancelbq headbq)You MUST apply --label key:value ONLY to subcommands that accept job
or resource labels (bq query, bq load, bq extract, bq mk, bq update,
and bq cp).
--label key:valuedatacloud:<ide><ide> with your actual environment/client
(e.g., vscode, antigravity, codex, cursor, cloud-shell,
workstation, gemini-cli, claude).
cloud-shell for GCP Cloud Shell.workstation for GCP Cloud Workstations. If you cannot determine
your environment, use ai-agent. Note that BigQuery labels cannot
contain dots or spaces.Incorrect:
bq query --use_legacy_sql=false "SELECT 1"
Correct (assuming you are running in VS Code):
bq query --use_legacy_sql=false --label datacloud:vscode "SELECT 1"
Incorrect:
bq cp dataset1.table1 dataset2.table1_copy
Correct (assuming you are running in Antigravity):
bq cp --label datacloud:antigravity dataset1.table1 dataset2.table1_copy
gcloud)Whenever you execute any gcloud command via run_command, you MUST
prepend the command with the CLOUDSDK_METRICS_ENVIRONMENT environment variable
to ensure proper resource attribution.
Environment Variable: prepend commands using the append form. It keeps any attribution another tool or skill already set on the same variable and adds the DAK tag after it, so both values reach the metrics pipeline:
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }datacloud.<ide>"
Deduction Rule: Substitute <ide> with your actual environment/client
(e.g., vscode, antigravity, codex, cursor, cloud-shell,
workstation, gemini-cli, claude).
cloud-shell for GCP Cloud Shell.workstation for GCP Cloud Workstations. If you cannot determine
your environment, use ai-agent. Note that values must use dots (e.g.,
datacloud.vscode), not colons.Incorrect:
gcloud compute disks create my-disk --size=10GB
Correct (assuming you are running in VS Code):
CLOUDSDK_METRICS_ENVIRONMENT="${CLOUDSDK_METRICS_ENVIRONMENT:+$CLOUDSDK_METRICS_ENVIRONMENT }datacloud.vscode" gcloud compute disks create my-disk --size=10GB
[!IMPORTANT]
This applies to ALL
gcloudcommands, whether they are read-only (gcloud ... list) or mutations (gcloud ... create).
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
resource-attribution, labeling, bigquery, gcloud, cli-tooling
41 skills in this plugin
/accidental-data-loss-prevention**STOP AND VERIFY**: Before running any command or tool that results in irreversible data loss, you MUST obtain explicit user consent.
When in doubt, ask. It is better to wait for confirmation than to accidentally delete production data or critical project assets.
Use this for:
- SQL: DROP TABLE/VIEW/SCHEMA/DATABASE, TRUNCATE, or broad DELETE (missing WHERE or using 1=1).
- Cloud Storage: gsutil rm or gcloud storage rm targeting production data or critical buckets.
- Infrastructure: gcloud projects delete, deleting Spanner/BigQuery/Dataproc resources, deleting secrets, or KMS key destruction.
/bigquery-ai-mlLeverages BigQuery's built-in machine learning and GenAI capabilities for advanced data analytics. Use when you need to write SQL queries that perform time-series forecasting, predict values, detect outliers or anomalies, find key drivers, perform semantic search or vector search, classify text, calculate similarity, summarize content, translate language, evaluate models, filter by semantic conditions, measure the causal effect of an intervention, compute correlations between columns, generate descriptive statistics and table distribution profiles, detect change points or structural breaks, extract trend or seasonality components, or leverage generative AI capabilities in BigQuery. Do not use for general BigQuery dataset, table, or job management requests./bigquery-bigframesGenerates Python code using BigQuery DataFrames (BigFrames). Use by default for any Python data task involving BigQuery, including data processing, analysis, and machine learning. Don't use for SQL-first workflows or the google-cloud-bigquery client library — use bigquery-basics./bigquery-data-transfer-serviceDiscovers and inspects BigQuery Data Transfer Service (DTS) configurations. Use this to identify existing ingestion pipelines and extract datasource or transfer config metadata for data pipelines. Use when a user asks for ingestion scenarios while building or managing data pipelines or when a user asks to "ingest" or "add" data that may already be managed by a DTS transfer./bigquery-graph-authorProvides an end-to-end journey for authoring a BigQuery property graph from your tables or from a model document/diagram (an ER diagram, an ontology, a semantic model): dataset discovery, candidate relationships verified against the data, a readable plan, and `CREATE PROPERTY GRAPH` DDL with schema best practices and semantic measures/dimensions, plus an opt-in verification suite for the landed graph. Use when creating or replacing a property graph, authoring a graph from a dataset or a document, or verifying relationships or suspicious edge counts. Don't use for querying an existing graph, for non-BigQuery graph databases, or for drawing/rendering diagrams./bigquery-graph-queryProvides guidelines and best practices for querying BigQuery property graphs and semantic graphs: native GQL (Graph Query Language) pattern matching, multi-hop and variable-length paths, aggregation, top-N, path extraction, output formatting (graph visualization with TO_JSON vs tabular), GRAPH_TABLE relational SQL integration, and semantic graph querying via the GRAPH_EXPAND TVF with starting-node view selection and AGG() measures. Also covers hybrid semantic search, combining `VECTOR_SEARCH` candidate generation with graph traversal when a node carries an embedding-backed property. Use when querying graph topology, node/edge connections, paths, or semantic measures over an existing BigQuery graph. Don't use for Cypher or non-BigQuery graph databases, or for creating/modifying a graph schema.npx claudepluginhub googlecloudplatform/data-agent-kit-plugin --plugin dakOther plugins' skills for the same job