---
title: "Ground PostgreSQL code generation in exact docs and best-practice skills through pg-aiguide"
description: "Give coding agents a PostgreSQL-specific reference layer with semantic doc search and curated schema, indexing, and constraint guidance before they generate database code."
verification: "listed"
source: "https://github.com/timescale/pg-aiguide"
author: "Timescale"
publisher_type: "organization"
category:
  - "Library & API Reference"
framework:
  - "MCP"
tool_ecosystem:
  github_repo: "timescale/pg-aiguide"
  github_stars: 1698
---

# Ground PostgreSQL code generation in exact docs and best-practice skills through pg-aiguide

Give coding agents a PostgreSQL-specific reference layer with semantic doc search and curated schema, indexing, and constraint guidance before they generate database code.

## Prerequisites

An AI coding agent with MCP support or npx skills support, plus optional access to the public pg-aiguide docs server.

## Installation

Choose whichever fits your setup:

1. Copy this skill folder into your local skills directory.
2. Clone the repo and symlink or copy the skill into your agent workspace.
3. Add the repo as a git submodule if you manage shared skills centrally.
4. Install it through your internal provisioning or packaging workflow.
5. Download the folder directly from GitHub and place it in your skills collection.

Install command or upstream instructions:

```
Add the MCP server at https://mcp.tigerdata.com/docs to your coding agent, or install the packaged skills with npx skills add timescale/pg-aiguide --skill postgres.
```

## Documentation

- https://github.com/timescale/pg-aiguide

## Source

- [Agent Skill Exchange](https://agentskillexchange.com/skills/ground-postgresql-code-generation-in-exact-docs-and-best-practice-skills-through-pg-aiguide/)
