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 0xMassi/claude-skills --skill postgres-strictgit clone --depth 1 https://github.com/0xMassi/claude-skillsWrote 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/0xmassi/claude-skills/postgres-strict)<a href="https://agentmods.dev/skills/0xmassi/claude-skills/postgres-strict"><img src="https://agentmods.dev/badge/skills/0xmassi/claude-skills/postgres-strict/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/0xmassi/claude-skills/postgres-strict"><img src="https://agentmods.dev/badge/skills/0xmassi/claude-skills/postgres-strict.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.00078 | $0.03237 |
| Opus 5 | $0.00039 | $0.01618 |
| Sonnet 5 | $0.00016 | $0.00647 |
| Haiku 4.5 | $0.00008 | $0.00324 |
Grade A, and why
postgres-strict 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 9d 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 — 374 lines — stays where its author put it; the contents beside it link to each section on GitHub.
PostgreSQL Strict Standard
Rules for production Postgres. Targets 16+ with notes for 17/18 features.
Version Targets
PostgreSQL 18 is GA (released Sept 2025). New deployments should target 18. Highlights worth designing around:
- Async I/O subsystem (AIO): sequential scans, bitmap heap scans, and
VACUUMissue concurrent reads instead of blocking each one. Up to ~3x faster on bulk-read workloads. No code change required. - Skip scan on B-tree indexes: multicolumn indexes can now be used when the leading column is not in the predicate, reducing the need for redundant index variants.
- Parallel GIN index builds:
CREATE INDEX ... USING ginruns in parallel. Big win for JSONB and full-text builds on large tables. uuidv7()native: no extension required (see PG-26 below).- Virtual generated columns are the default: stored columns require explicit
STORED. Virtual columns compute on read, no write amplification. OLDandNEWinRETURNING: capture the row state before and afterUPDATE/DELETE/MERGEin one statement.- OAuth 2.0 authentication in libpq: easier SSO integration.
- Planner stats survive major version upgrades: post-upgrade clusters reach steady-state performance much faster, no immediate
ANALYZEstorm.
CRITICAL: Migration Safety
A migration is a contract with a running system. The wrong migration takes prod down.
PG-01: CREATE INDEX CONCURRENTLY on hot tables
-- BAD: takes ACCESS EXCLUSIVE lock for the duration of the build
CREATE INDEX events_user_id_idx ON events (user_id);
-- GOOD: short ACCESS EXCLUSIVE on metadata, no row lock during build
CREATE INDEX CONCURRENTLY events_user_id_idx ON events (user_id);
CONCURRENTLY cannot run inside a transaction block. Migration tools that wrap statements in BEGIN/COMMIT must opt out for these statements. Failed concurrent index builds leave an INVALID index, drop and retry.
PG-02: Add NOT NULL columns in two steps
-- BAD: rewrites the whole table while holding ACCESS EXCLUSIVE
ALTER TABLE users ADD COLUMN status text NOT NULL DEFAULT 'active';
-- GOOD on PG 11+ for defaults, but still problematic if you need NOT NULL on existing nulls
ALTER TABLE users ADD COLUMN status text DEFAULT 'active';
-- Backfill in batches in app code
UPDATE users SET status = 'active' WHERE status IS NULL AND id BETWEEN $1 AND $2;
ALTER TABLE users ALTER COLUMN status SET NOT NULL;
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.
- 9d ago First seen · 374 lines · 78 tokens per session scan A 120d305c368b
postgres-strict is a skill published in the GitHub repository 0xMassi/claude-skills (7 stars, last pushed 4mo ago), licensed MIT. It adds 78 tokens to every session and 3,237 once invoked, about $0.0004 per session on Opus 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-31.
Other skills, from other repositories
database-migrator
Migrates databases between providers (Postgres, MySQL, Supabase, PlanetScale, MongoDB). Reads source schema, generates migration scripts, handles data type mapping, foreign keys, indexes, triggers, stored procedures. Validates migration with row counts and checksums. Generates migration-plan.md with step-by-step…
database-schema-designer
Design optimized database schemas for SQL and NoSQL databases including tables, relationships, indexes, and constraints. Creates ERD diagrams, migration scripts, and data modeling best practices. Use when users need database design, schema optimization, or data architecture planning.
using-relational-databases
Relational database implementation across Python, Rust, Go, and TypeScript. Use when building CRUD applications, transactional systems, or structured data storage. Covers PostgreSQL (primary), MySQL, SQLite, ORMs (SQLAlchemy, Prisma, SeaORM, GORM), query builders (Drizzle, sqlc, SQLx), migrations, connection pooling…
sql-optimization
A guide to improving SQL queries, the commands used to read and change data in databases. It covers examining how MySQL and PostgreSQL execute queries and designing indexes that help them find data faster.
postgresql
A guide for administering PostgreSQL, a database system that stores application data and supports SQL queries. It covers connections, users and permissions, database objects, backups, extensions, and query optimisation.
postgresql-table-design
Use this skill when designing or reviewing a PostgreSQL-specific schema. Covers best-practices, data types, indexing, constraints, performance patterns, and advanced features.