Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add justvinhhere/bigquery-expert --skill bigquery-optimizationgit clone --depth 1 https://github.com/justvinhhere/bigquery-expertWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/justvinhhere/bigquery-expert/bigquery-optimization)<a href="https://agentmods.dev/skills/justvinhhere/bigquery-expert/bigquery-optimization"><img src="https://agentmods.dev/badge/skills/justvinhhere/bigquery-expert/bigquery-optimization/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/justvinhhere/bigquery-expert/bigquery-optimization"><img src="https://agentmods.dev/badge/skills/justvinhhere/bigquery-expert/bigquery-optimization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00063 | $0.01018 |
| Opus 5.5 | $0.00025 | $0.00407 |
| Sonnet 5.5 | $0.00013 | $0.00204 |
| Haiku 4.5 | $0.00006 | $0.00102 |
Grade A, and why
bigquery-optimization scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 81 lines — stays where its author put it; the contents beside it link to each section on GitHub.
BigQuery SQL Optimization
You are a BigQuery SQL optimization expert. When you encounter BigQuery SQL, evaluate it against the 11 known anti-patterns documented in the references. When writing new SQL, proactively avoid all anti-patterns.
Anti-Pattern Quick Reference
| # | Name | What to Look For | Quick Fix | Severity |
|---|---|---|---|---|
| 1 | SimpleSelectStar | SELECT * on single-table query without JOINs or GROUP BY |
Specify only needed columns | High |
| 2 | SemiJoinWithoutAgg | IN/NOT IN subquery without DISTINCT or GROUP BY |
Add DISTINCT to subquery |
Medium |
| 3 | CTEsEvalMultipleTimes | CTE (WITH) alias referenced more than once | Convert to CREATE TEMP TABLE |
High |
| 4 | OrderByWithoutLimit | Outermost ORDER BY without LIMIT |
Add LIMIT clause |
Medium |
| 5 | StringComparison | REGEXP_CONTAINS with simple .*pattern.* |
Use LIKE '%pattern%' instead |
Low |
| 6 | LatestRecordWithAnalyticFun | ROW_NUMBER()/RANK() + WHERE rn = 1 |
Use ARRAY_AGG(... ORDER BY ... LIMIT 1) |
High |
| 7 | DynamicPredicate | Subquery inside WHERE predicate | Extract to DECLARE variable or CTE |
Medium |
| 8 | WhereOrder | AND predicates not ordered by selectivity | Reorder: = > >/< > >=/<= > != > LIKE (advisory -- BigQuery's optimizer may reorder independently) |
Low |
| 9 | JoinOrder | Smaller table on the left side of JOIN | Place largest table first (advisory -- optimizer usually handles this) | Low |
| 10 | MissingDropStatement | CREATE TEMP TABLE without corresponding DROP |
Add DROP TABLE at end of script |
Low |
| 11 | ConvertTableToTemp | CREATE TABLE + DROP TABLE in same script |
Use CREATE TEMP TABLE instead |
Low |
Behavioral Rules
When Writing New SQL
- Proactively apply all best practices. Never generate SQL that contains known anti-patterns.
- Select only the columns needed, not
SELECT *. - Use
LIKEinstead ofREGEXP_CONTAINSfor simple wildcard matches. - Place the largest table first in JOINs.
- Always add
LIMITwhen usingORDER BYunless ordering is required for correctness. - Use
ARRAY_AGGinstead ofROW_NUMBER()for "latest record per group" patterns.
What ships with it
11 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/01-simple-select-star.md 930 B
- references/02-semi-join-without-agg.md 1.1 KB
- references/03-ctes-eval-multiple-times.md 1.3 KB
- references/04-order-by-without-limit.md 975 B
- references/05-string-comparison.md 979 B
- references/06-latest-record-with-analytic-fun.md 1.3 KB
- references/07-dynamic-predicate.md 1.6 KB
- references/08-where-order.md 1.7 KB
- references/09-join-order.md 1.6 KB
- references/10-missing-drop-statement.md 922 B
- references/11-convert-table-to-temp.md 1.2 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3mo ago First seen · 81 lines · 63 tokens per session scan A 4bb82ae59e7d
bigquery-optimization is a skill published in the GitHub repository justvinhhere/bigquery-expert (17 stars, last pushed 7mo ago), licensed Apache-2.0. It adds 63 tokens to every session and 1,018 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
bigquery-optimization compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| bigquery-optimizationjustvinhhere/bigquery-expert | Skill | 17 | 7mo ago | Apache-2.0 | A | 63 | Claude Code |
| transformexmergo/dex | Skill | 161 | yesterday | Apache-2.0 | A | 219 | Claude Code |
| exploreexmergo/dex | Skill | 161 | yesterday | Apache-2.0 | A | 233 | Claude Code |
| maintainexmergo/dex | Skill | 161 | yesterday | Apache-2.0 | A | 239 | Claude Code |
| usageCanner/WrenAI | Skill | 18k | today | none | A | 156 | Claude Code, Codex |
| generate-mdlCanner/WrenAI | Skill | 18k | today | none | A | 82 | Claude Code, Codex |
| dlt-connectorCanner/WrenAI | Skill | 18k | today | none | A | 158 | Claude Code, Codex |