Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By jggomezApache-2.0In 1 marketplace
Finds slow SQL in files and app code, then rewrites it with reasoning drawn from BigQuery or EXPLAIN plans. A hook denies destructive DDL and any bq query lacking --dry_run, and without credentials it marks reports STATIC_ANALYSIS_ONLY.
Trending plugins
7-day copy clicks
Claude hands work to one, or you mention it with @.
3 cautions to review before installing
A hook runs when Claude uses the Bash tool
A hook runs when Claude writes or edits files
Connects to a remote server outside your machine
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Diagnoses and rewrites slow BigQuery and relational SQL using real execution plans, for Claude Code.
sql-query-optimizer finds slow SQL in standalone .sql files and in queries embedded in application code.
It diagnoses BigQuery query plans (shuffle, skew, partition pruning) or EXPLAIN plans on Postgres, MySQL and SQL Server, then rewrites each query with the reasoning behind the change.
A safety hook keeps it read-only: destructive DDL is denied and every bq query must be a dry run.
| Needs | For |
|---|---|
node on PATH | Running the safety hook |
python3 | The static linter lint_sql_query.py |
bq / gcloud with Application Default Credentials (optional) | BigQuery dry runs and the bigquery MCP server |
Database access, e.g. psql (optional) | EXPLAIN / EXPLAIN ANALYZE on relational engines |
Without credentials the agent still works, but marks its report STATIC_ANALYSIS_ONLY.
claude plugin marketplace add jggomez/expert-ai-developer-skills
claude plugin install sql-query-optimizer@expert-ai-developer-skills
Updates, per-project settings, local development and limitations: Claude Code installation guide.
Use the sql-query-optimizer agent to find why reports/daily_revenue.sql scans so many bytes in BigQuery.
Audit all SQL in src/ for missing indexes and slow pagination on Postgres.
Run the static BigQuery linter on its own, from the plugin root (no connection needed):
python3 skills/bigquery-query-optimization/scripts/lint_sql_query.py path/to/sql
| Agent | Role | Model |
|---|---|---|
sql-query-optimizer | Scans .sql files and embedded SQL, identifies the dialect, reads plans, and rewrites queries as Original / Optimized / Reasoning | inherit |
| Event | Script | Behavior |
|---|---|---|
PreToolUse (Bash) | hooks/sql-safety-gate.js | Denies DROP TABLE/VIEW/SCHEMA/DATABASE/INDEX, TRUNCATE and ALTER TABLE ... DROP. Denies any bq query without --dry_run. |
| Server | Command | Purpose |
|---|---|---|
bigquery | HTTP https://bigquery.googleapis.com/mcp | BigQuery schemas and query plans |
cloudsql | HTTP https://sqladmin.googleapis.com/mcp/query_execution (OAuth, Cloud SQL scope) | Query execution against Cloud SQL for EXPLAIN plans |
| Skill | Purpose |
|---|---|
bigquery-query-optimization | Plan-based BigQuery tuning: partition/cluster pruning, JOIN order, broadcast vs. shuffle, skew; includes lint_sql_query.py |
sql-query-optimization | EXPLAIN / EXPLAIN ANALYZE tuning for Postgres, MySQL, SQL Server: indexes, selectivity, CTE vs. subquery, pagination |
context-restore | Reads context/memory/MEMORY.md at audit start to reuse known partition, cluster and index keys |
context-capture | Records optimization baselines and index/partition recommendations in context/memory/ |
context/memory/MEMORY.md if it exists and classifies the task as Tier 1, 2 or 3..py, .js, .ts, .java, .go, .rb, .scala) and identifies the dialect.bq query --dry_run or EXPLAIN to get a real plan. If that fails, it marks the result STATIC_ANALYSIS_ONLY / BLOCKED and never invents byte counts or latencies.context/memory/ through context-capture.| Symptom | Cause | Fix |
|---|---|---|
"bq query" command requires "--dry_run" flag | The hook denies every live bq query | Add --dry_run; run the real query yourself if needed |
[SQL SAFETY GATE VIOLATION]: Destructive ... statement blocked | The command contains DROP, TRUNCATE or ALTER TABLE ... DROP | Review and run it outside the agent |
Report says STATIC_ANALYSIS_ONLY | No credentials or the database is unreachable | Configure Application Default Credentials or database access, then rerun |
| Linter finds nothing in a directory | Only .sql files and string literals with SELECT/INSERT/UPDATE/DELETE ... FROM are scanned | Point it at the file or folder that holds the queries |
senior-data-engineer: designs the pipelines whose SQL this plugin tunes.shared-context: the context/memory/ store shared across sessions and hosts.7-day copy clicks
Plugins from other owners that cover similar ground
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.
npx claudepluginhub jggomez/expert-ai-developer-skills --plugin sql-query-optimizer