postgres-pro

Analyze PostgreSQL queries with EXPLAIN ANALYZE and recommend indexes.

1|Updated Mar 27, 2026
One-click install
npx skills add https://github.com/tchawla827/GraphForge --skill postgres-pro-tchawla827
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: postgres-pro
Source: https://github.com/tchawla827/GraphForge/tree/main/.claude/skills/postgres-pro
Command: npx skills add https://github.com/tchawla827/GraphForge --skill postgres-pro-tchawla827

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps database professionals optimize PostgreSQL performance by analyzing slow queries, designing indexes, tuning maintenance, and configuring replication for reliable and scalable systems.

Core Features & Use Cases

  • Query analysis & plan optimization: Use EXPLAIN ANALYZE to identify bottlenecks and verify performance improvements.
  • Index design & tuning: Create and tune B-tree, GIN, GiST, and BRIN indexes for common access patterns, including partial and covering indexes.
  • JSONB optimization & maintenance: Optimize JSONB queries and manage maintenance tasks to keep workloads responsive, with replication and backups in mind.
  • Replication & high availability: Establish and validate primary/standby configurations to support read scaling and failover.
  • Use Case: When a production database experiences slow report generation, apply recommended indexing and query refactoring to reduce latency.

Quick Start

Provide a slow-running query and I will analyze its plan with EXPLAIN ANALYZE and propose indexing and tuning steps.

Frequently Asked Questions about postgres-pro

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

FAQPage Schema
How do I optimize slow PostgreSQL queries using EXPLAIN ANALYZE?

To optimize slow PostgreSQL queries, use EXPLAIN ANALYZE to identify execution bottlenecks and verify performance improvements. This Skill analyzes the provided query plan and proposes specific indexing and tuning steps to reduce latency.

What are the best PostgreSQL index types for JSONB optimization?

For JSONB optimization, GIN and GiST indexes are highly effective for common access patterns. This Skill provides index design recommendations, including partial and covering indexes, to keep JSONB query workloads responsive.

How do I configure PostgreSQL replication for high availability?

Configuring PostgreSQL replication for high availability involves establishing and validating primary/standby configurations. This Skill provides best-practice guidance to support read scaling and ensure reliable database failover across production environments.

When should I use B-tree vs BRIN indexes in PostgreSQL?

B-tree indexes suit standard equality and range queries, while BRIN indexes excel for large, naturally ordered tables. This Skill analyzes your specific access patterns to recommend the correct index design for performance tuning.

Does PostgreSQL index tuning work well for production report generation?

PostgreSQL index tuning effectively resolves slow production report generation by applying recommended indexing and query refactoring. This reduces latency and maintains workload reliability from development to production environments.

What PostgreSQL maintenance strategies keep workloads responsive?

PostgreSQL maintenance strategies to keep workloads responsive include managing routine maintenance tasks alongside JSONB optimization and replication tuning. This ensures reliable and scalable systems across development and production environments.