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 agentmods add skills/paultyng/skill-issue/review-databasenpx skills add paultyng/skill-issue --skill review-databasegit clone --depth 1 https://github.com/paultyng/skill-issueWrote 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/paultyng/skill-issue/review-database)<a href="https://agentmods.dev/skills/paultyng/skill-issue/review-database"><img src="https://agentmods.dev/badge/skills/paultyng/skill-issue/review-database.svg" alt="Measured on agentmods" 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 | $0.00062 | $0.01939 |
| Opus 5 | $0.00031 | $0.00970 |
| Sonnet 5 | $0.00012 | $0.00388 |
| Haiku 4.5 | $0.00006 | $0.00194 |
Grade B, and why
review-database scanned grade B with 1 finding 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 4d 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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
- Findings must cite probed evidence (`path:line`, grep output, command result), not pattern-matched suspicion. Per `~/.claude/rules/probe-not-assume.md`. How it starts
The opening of the file, as written. The whole thing — 132 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Database & SQL Review
Structured database review producing actionable, prioritized findings with code-level references.
Workflow
1. Scope and explore
- Confirm scope with the user: full codebase, specific packages/directories, specific migrations, changed files only (PR or branch diff), or specific concern.
- Resolve scope to a file/package list. Based on what the user requested:
- Changed files (PR or branch): Run
git diff --name-only --diff-filter=d <base>...HEADto get changed files (default<base>ismain). If the user references a PR number, usegh pr diff <number> --name-onlyinstead. Filter to relevant file types (.go,.sql). Derive affected Go packages from the file paths (unique parent directories containing.gofiles). - Explicit paths/packages: The user may specify directories (e.g.
internal/store/), Go package patterns (e.g../internal/store/...), individual files, or specific migration files. When given a directory or package pattern, include all files under it. - Full codebase: No filtering. Explore everything (default).
- Changed files (PR or branch): Run
- Pass the resolved scope (file list) to all exploration and investigation subagents so they only read and analyze scoped files.
- Explore the scoped code using parallel subagents (
subagent_type="explore"). Read all in-scope.sqlfiles, schema definitions, and source files that interact with the database (queries, connection setup, transaction handling).
2. Launch investigation subagent
Launch a single investigation subagent (subagent_type="generalPurpose", model: sonnet per subagent-model-routing) with the list of in-scope files.
Prompt it to:
- Read all in-scope
.sqlfiles, schema definitions, and source files that interact with the database. - Detect which database engine is in use by checking imports (
pgx,pq,lib/pqfor PostgreSQL;go-sql-driver/mysqlfor MySQL), migration tool configs, and connection strings. Apply the appropriate engine-specific checklist from reference.md. - Analyze against all database categories: migration safety, query performance, connection & transaction management, and schema design (see reference.md).
- Detect if horizontal sharding is in use (VSchema files, Citus distribution config, Spanner interleaved tables, shard-routing middleware, or multi-column partition keys). If detected, analyze hot-path queries against the checklist in reference-sharding.md: flag scatter queries, missing sharding keys in WHERE clauses, cross-shard JOINs, and cross-shard transactions.
- For PostgreSQL projects: check if
npxis on PATH (which npx). If available, runnpx squawk-cli <migration_files>against in-scope.sqlmigration files only (when scope is narrowed, limit to.sqlfiles in the resolved file list). Ifnpxis not available, check forsquawkdirectly on PATH. If neither is available, note in Tool Availability and continue with manual review only. - Include a Tool Availability section listing each tool's status (ran / skipped + reason).
- For each finding, search nearby code and project documentation for existing TODOs or notes.
- Return findings using the per-category findings template with
DB-prefixed IDs (e.g.DB1,DB2). - Every finding must include specific file paths, line numbers or function names, a severity rating (CRITICAL / HIGH / MEDIUM / LOW), and tracking status.
What ships with it
2 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.
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.
- 4d ago First seen · 132 lines · 62 tokens per session scan B adc54362d2bb
review-database is a skill published in the GitHub repository paultyng/skill-issue (9 stars, last pushed 23d ago), licensed MIT. It adds 62 tokens to every session and 1,939 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
postgresql
PostgreSQL schema design, query optimization, indexing, and administration. Use when working with PostgreSQL, JSONB, partitioning, RLS, CTEs, window functions, or EXPLAIN ANALYZE.
postgresql
PostgreSQL schema design, query optimization, indexing, and administration. Use when writing schemas, queries, migrations, or mentions PostgreSQL, Postgres, JSONB, partitioning, RLS, CTEs, window functions, EXPLAIN ANALYZE, or connection pooling.
factory-data-layer
Database schema, ORM, and migration conventions across builds. Drizzle as default with domain-partitioned schema modules, shared timestamps helper, multi-tenancy keys with cascade delete, pgTableCreator prefixing, JSONB for flexible attributes, schema-derived type exports, polymorphic table patterns, ESLint Drizzle…
sql-expert
Expert SQL & relational databases: queries, schema design, indexing, query-plan optimization, and transactions (Postgres/MySQL/SQLite). Trigger keywords: SQL, database, Postgres, MySQL, SQLite, JOIN, index, EXPLAIN, query plan, slow query, N+1, normalization, transaction, isolation, deadlock, migration. Use for…
bitrix-postgresql
Covers PostgreSQL support in Bitrix — PgsqlConnection, migration from MySQL, compatible code, module support matrix. Applied when configuring or migrating to PostgreSQL Enterprise editions. Key terms — PostgreSQL, PgsqlConnection, migration, compatible-code.
sql_mastery
CREATE OR REPLACE PROCEDURE sprefreshattributiondaily() LANGUAGE plpgsql AS $$ BEGIN -- 1. Truncate Staging TRUNCATE TABLE stgdailytraffic.