SkillsReviewed · wshobson

PostgreSQL Table Design

PostgreSQL Table Design is an assistant skill for developers creating or reviewing PostgreSQL schemas, but its categorical recommendations need checking against the database version and workload. It pairs a concise guide with a deeper reference covering column types, constraints, indexes, partitioning, JSONB and schema changes.

Researched 17 Nov 2026

In short.

PostgreSQL Table Design is an assistant skill for developers designing PostgreSQL databases, but several broad rules require version and workload checks before use. Its two Markdown files provide practical schema examples and guidance on data types, integrity constraints, indexes, partitioning, JSONB and write-heavy workloads. It offers substantial material for a design discussion, while assistant compatibility, SQL correctness in a target environment, migration downtime and performance remain unassessed. Nothing was executed or tested.

Researched and written by an AI model and checked by a second AI model. How it works

Covers plugins/database-design/skills/postgresql-table-design/SKILL.md and its companion references/details.md at revision 9c61ab243def98f72da12abd41cfcf5bcd91af9d, with the repository-root LICENSE as the accompanying notice outside that folder. Other repository skills, plugin installation files and extension implementations are outside this scope. Assistant loading, generated output, SQL execution, performance and live migration behavior were not tested.

The overview

identity

PostgreSQL Table Design is the postgresql-table-design skill in the wshobson/agents repository. A skill supplies written instructions that an assistant can use when answering a task. This one focuses on PostgreSQL schema design and review, with SKILL.md as its entry point and references/details.md as its companion reference.

The original source folder is [https://github.com/wshobson/agents/tree/main/plugins/database-design/skills/postgresql-table-design]. The described source revision is 9c61ab243def98f72da12abd41cfcf5bcd91af9d.

assessment

The skill provides a useful starting checklist for discussing a schema with an assistant. It connects ordinary decisions, such as required fields and foreign keys, with PostgreSQL-specific concerns including identity gaps, dead row versions, index types and partitioned-table constraints.

Its breadth is useful, but its prescriptive tone can obscure tradeoffs. Defaults such as BIGINT identifiers, particular string types and extension choices should be evaluated against application needs. The documents do not establish the quality of an assistant's resulting designs.

users

Beginners can use the users, orders and profiles examples to understand how column types, required values, relationships and indexes fit together. Some reference topics, including operator classes, HOT updates and row-level security, require additional PostgreSQL knowledge.

Experienced developers can use it to structure reviews of update-heavy tables, bulk ingestion, optional JSONB attributes and partitioning. Teams planning changes to a live database will need additional evidence about locking, rollout and recovery for their particular environment.

capabilities

The material covers identifiers, numeric and time types, normalization, primary and foreign keys, uniqueness, checks and exclusion constraints. Index guidance includes B-tree, GIN, GiST, BRIN, composite, partial, expression and covering indexes.

The reference adds temporary and unlogged tables, row-level security, workload patterns, generated columns, extension choices and JSONB indexing strategies. These are subjects the skill can guide an assistant through; the supplied folder contains no implementation for automatically inspecting a database or applying changes.

Using it

requirements

Practical use requires an assistant that can consume the Markdown instructions, plus enough application context to explain relationships and query patterns. Applying the SQL requires a suitable PostgreSQL environment and database permissions; neither is needed merely to read the documents.

The files mark NULLS NOT DISTINCT as PostgreSQL 15+ and uuidv7() and virtual generated columns as PostgreSQL 18+. Features involving citext, PostGIS, TimescaleDB or pgvector depend on those extensions. An overall minimum PostgreSQL release, supported assistant list and extension compatibility matrix are unknown.

mechanism

SKILL.md begins with a name and description, then supplies usage scenarios, design rules, cautions and examples. It points to references/details.md for deeper topics, allowing an assistant to consult additional material when needed.

The mechanism is written guidance. It supplies no model, database connection, execution engine or automated enforcement. Whether an assistant loads the companion reference and follows the guidance consistently has not been assessed.

setup

Keep SKILL.md and references/details.md together in their original relative layout so the reference path remains meaningful. Use the skill-loading mechanism documented by the chosen assistant. These files do not specify an installation command, registration location or activation procedure.

For a useful design request, provide the PostgreSQL version, existing schema or intended entities, representative queries and expected write patterns. Include any restrictions on extensions and live schema changes.

example

The users example defines an identity-generated BIGINT primary key, required email and name fields, and a TIMESTAMPTZ creation time. It combines a UNIQUE email constraint with a separate unique index on LOWER(email), and adds an index on created_at.

The orders example adds a user foreign key, a three-value status check and total NUMERIC(10,2) NOT NULL CHECK (total > 0), followed by explicit indexes on user_id and created_at. The profiles example stores JSONB attributes, generates a theme column from them and creates a GIN index on attrs. It does not create an index on theme. These examples were not executed.

Assessment & evidence

limitations

Some advice is expressed more categorically than the supplied support establishes. The reference labels now() a volatile default that causes a table rewrite and says partial indexes do not work with ON CONFLICT. The main guide says filtering only on b cannot use an index on (a,b). These claims need verification against the target PostgreSQL release before they guide a migration or index decision.

The guidance also uses broad defaults and a greater-than-100-million-row guideline for query-driven partitioning without workload measurements. Claims about faster writes, index performance and downtime are not accompanied by benchmarks or execution results. The live-database guidance does not establish a complete deployment or recovery procedure.

reasoning

The skill's strongest organizing idea is to connect schema choices to actual access patterns. The main guide asks for indexes on queried paths, while the reference warns that each index adds insert overhead and discusses separating frequently updated columns.

That combination supports useful discussions about read speed, write cost and storage. Its value depends on supplying workload details and asking the assistant to explain each choice. A schema generated from the rules alone has no demonstrated performance advantage.

alternatives

The material itself offers several design alternatives: expression indexes or citext for case-insensitive values, declarative partitioning or TimescaleDB-managed tables, and native geometric types or PostGIS. These choices address different requirements; the files provide no comparative benchmarks or deployment-cost analysis.

For disputed behavior and version boundaries, consult the documentation for the deployed PostgreSQL release and any chosen extension. Other assistant skills and schema-design tools were not assessed.

evidence

The source material consists of SKILL.md, references/details.md and the repository-level LICENSE at commit 9c61ab243def98f72da12abd41cfcf5bcd91af9d. The documents contain design recommendations and SQL examples, but no results from running the examples or evaluating assistant output.

The versioned originals are [https://raw.githubusercontent.com/wshobson/agents/9c61ab243def98f72da12abd41cfcf5bcd91af9d/plugins/database-design/skills/postgresql-table-design/SKILL.md] and [https://raw.githubusercontent.com/wshobson/agents/9c61ab243def98f72da12abd41cfcf5bcd91af9d/plugins/database-design/skills/postgresql-table-design/references/details.md].

Access & freshness

costs

The documents state no purchase price, subscription charge or required paid provider. Assistant usage, database infrastructure and any external service costs are unknown. No measured implementation cost, operating savings or return on investment is provided.

rights

The accompanying repository LICENSE is the MIT License, copyright 2024 Seth Hobson. It permits use, copying, modification, publication, distribution, sublicensing and sale, provided the copyright and permission notice accompanies copies or substantial portions.

The licence disclaims warranties and limits liability. It supports redistribution of these source documents with the notice; it does not establish the terms of third-party extensions or services mentioned in the text. The original notice is [https://raw.githubusercontent.com/wshobson/agents/9c61ab243def98f72da12abd41cfcf5bcd91af9d/LICENSE].

freshness

The source snapshot was captured on 17 November 2026 at 08:22:18.521 UTC. That date identifies the snapshot, not the documents' publication or last modification date.

The text includes features labelled PostgreSQL 18+, but gives no skill release number or complete supported-version range. Whether the repository's current main branch differs from the stated commit is unknown.

actions

Start with one concrete schema and provide the database version, relationships, common filters, joins, sorting and expected writes. Ask the assistant to explain how each proposed constraint and index serves those requirements.

Verify version-sensitive and categorical claims against the relevant documentation. Before applying resulting SQL to a live database, assess it in a representative non-production environment, including query plans, write overhead, locking and recovery. No such validation has been performed here.

Evidence for this report

LICENSEnotice · checked 2026-11-17