| name | bq-init-project |
| description | Initialize project-local BigQuery agent documentation. Use when a project needs BigQuery support, docs/bigquery setup, query safety preferences, table catalog conventions, or a local AGENTS.md for BigQuery workflows. |
bq-init-project
Initialize BigQuery support inside the target project. Do not edit this plugin
repo unless the user is developing the plugin itself.
Required Confirmations
Before writing files, confirm the project-specific choices that cannot be inferred:
- Default GCP project. Use
research-bigquery-playground only when the user accepts it or the project already uses it.
- Default dataset, if the project has one.
- Query scan approval threshold. Default to
100GB.
- Whether SELECT queries under the threshold may run after dry-run.
- Whether DML, DDL, export, or load jobs are allowed. Default: ask before any of them.
- Whether public datasets should be documented in this project.
Never record access tokens, ADC files, local credential paths, or account emails in
project docs.
Directory Layout
Create only the BigQuery docs root and table catalog:
docs/bigquery/
├── AGENTS.md
└── tables/
Do not create docs/bigquery/queries/ by default. Query files and extraction
scripts belong wherever the target project normally keeps executable SQL or code.
AGENTS.md Template
Write docs/bigquery/AGENTS.md with these sections:
# BigQuery Agent Notes
## Defaults
- Default project: `<project>`
- Default dataset: `<dataset or none>`
- Location/region: `<region or unknown>`
- Query scan approval threshold: `100GB`
## Safety Rules
- Always run a dry-run before executing a BigQuery query that scans table data.
- SELECT queries with estimated bytes processed at or below the threshold may run without another confirmation.
- Queries above the threshold require explicit user approval.
- DML, DDL, export jobs, and load jobs require explicit user approval unless this file says otherwise.
- Do not write credentials, access tokens, ADC paths, or account emails into this directory.
## Table Catalog
- Store table docs under `docs/bigquery/tables/<project>/<dataset>/<table>.md`.
- Prefer one file per BigQuery table.
- Keep project-specific semantics in table docs, not in the global plugin.
## Notes
- Add only tables this project actually uses.
- Public datasets may be documented when they are part of this project's workflow.
Adjust defaults to the user's answers. Keep the file short; it is for agents,
not for end-user tutorial prose.