Skip to main content
Glama
chncaesar

pg-semantic-mcp

by chncaesar

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LLM_MODELNoLLM model namegpt-4o-mini
LLM_API_KEYNoRequired for search_schema
DATABASE_URLYesPostgreSQL connection string
LLM_BASE_URLNoOpenAI-compatible endpointhttps://api.openai.com/v1
CACHE_SCHEMASNoComma-separated schema names to cacheall
SEMANTIC_FILENoPath to your semantic layer markdown
SAMPLE_DATA_LIMITNoDefault row count for sample_data5
CACHE_REFRESH_MINUTESNoBackground cache refresh interval30

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_tablesA

List all tables in the database with their comments.

describe_tableA

Return column metadata for a table.

sample_dataA

Return sample rows from a table.

search_schemaA

Semantically search tables and columns by keyword using LLM.

Combines the in-memory schema cache and the semantic layer markdown (if configured) into a prompt, then calls the configured LLM to find relevant tables and columns.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/chncaesar/pg-semantic-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server