postgresql-optimization

Optimize PostgreSQL queries, JSONB indexing, and schema design for complex workloads.

Updated May 25, 2026
One-click install
npx skills add https://github.com/yehezkieldio/formalist --skill postgresql-optimization-yehezkieldio
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: postgresql-optimization
Source: https://github.com/yehezkieldio/formalist/tree/main/.agents/skills/postgresql-optimization
Command: npx skills add https://github.com/yehezkieldio/formalist --skill postgresql-optimization-yehezkieldio

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides expert guidance to optimize PostgreSQL queries, data types, indexing, and extensions, bridging performance gaps in complex workloads.

Core Features & Use Cases

  • JSONB optimization and indexing
  • Advanced data types and ranges
  • Window functions and analytics
  • Full-text search tuning and text search vector optimization
  • Extension ecosystem exploration and maintenance
  • Query tuning, plan analysis, and performance diagnostics
  • Schema design and normalization for performance

Quick Start

Provide a PostgreSQL query or schema to optimize and I will generate a step-by-step plan focusing on indexing, JSONB, and advanced data types.

Frequently Asked Questions about postgresql-optimization

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I optimize PostgreSQL queries for complex workloads?

PostgreSQL query optimization requires analyzing execution plans and applying targeted indexing strategies. By tuning queries and refining schema design, you resolve performance bottlenecks in complex workloads and improve execution speed for advanced data types.

What is the best way to index JSONB operations in PostgreSQL?

Indexing JSONB operations requires specialized strategies like GIN or GiST indexes to accelerate data retrieval. By optimizing text search vectors and applying proper data modeling, you ensure efficient querying and filtering within complex JSON document structures.

How do I tune full-text search and text search vectors in PostgreSQL?

Full-text search tuning involves optimizing text search vectors and configuring appropriate indexes. By analyzing query plans and adjusting search configurations, you enhance search accuracy and accelerate text retrieval performance across large database schemas.

When do I need advanced data types and range types for data modeling?

Advanced data types and range types are needed when modeling complex constraints and temporal data in PostgreSQL. By utilizing these specialized types during schema design and normalization, you enforce data integrity and enable highly efficient range-based queries.

Does PostgreSQL extension usage affect query performance and maintenance?

PostgreSQL extension usage directly impacts query performance and requires ongoing maintenance. Exploring the extension ecosystem allows you to add specialized functionality, but you must monitor and tune these extensions to prevent performance degradation in complex workloads.

Why does my PostgreSQL schema design cause slow window functions?

Slow window functions often stem from poor schema normalization and missing indexes. By performing query tuning, analyzing execution plans, and restructuring your data modeling, you eliminate performance bottlenecks and optimize analytical query execution.