Postgresql optimization
Skill kimtth/agent-skill-100-lines-or-less/skills/postgresql-optimization
🧿 Minimal but effective AI agent skill definitions in 100 lines or less.
npx -y skills add kimtth/agent-skill-100-lines-or-less --skill postgresql-optimizationAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 2 stars2 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Use when: improve PostgreSQL schema, queries, indexes, JSONB, arrays, full-text search, or performance with Postgres-specific features.
SKILL.md
1.4 KB, 278 tokens by cl100k_base, as published. Nobody here has run it
Goal: use PostgreSQL features deliberately and measure performance with evidence.
Use for:
- slow queries, missing indexes, schema design, and data modeling
- JSONB, arrays, custom types, ranges, full-text search, and extensions
- window functions, CTEs, materialized views, and analytics queries
- migration review and Postgres-specific refactors
Workflow:
- Identify table sizes, query shape, filters, joins, and expected latency.
- Run or request
EXPLAIN (ANALYZE, BUFFERS)for performance work. - Check existing indexes, constraints, and data distribution.
- Pick the smallest Postgres feature that solves the real bottleneck.
- Propose migration SQL plus rollback when schema changes are needed.
- Verify with query plans, tests, and representative data.
Patterns:
- JSONB: GIN indexes, containment, path extraction, generated columns
- arrays:
ANY, overlap, containment, unnest only when needed - text search:
tsvector, GIN, ranking, language config - analytics: window functions over app-side loops
- indexing: composite order, partial indexes, covering indexes
Rules:
- do not add indexes without a query they serve
- do not optimize synthetic tiny data as if it were production
- keep migrations reversible when possible
- measure before and after
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.