Skip to main content
Glama
mittalpk

mcp-server-pgvector

by mittalpk

hybrid_search

Blend vector similarity and Postgres full-text search to rank rows by relevance. Configure weights to balance semantic and keyword matching for hybrid retrieval.

Instructions

Rank rows by a weighted blend of vector similarity and Postgres full-text search.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
kNo
tableYes
metricNocosine
schemaNopublic
query_textYes
text_columnYes
vector_weightNo
return_columnsNo
query_embeddingYes
embedding_columnYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Since no annotations are provided, the description must carry the full burden of behavioral disclosure. It does explain the core mechanism ('weighted blend of vector similarity and full-text search') and the ranking behavior. However, it does not disclose potential edge cases, performance implications, or how the weighting affects results. This is a moderate level of transparency, similar to the update_drive example but with less risk (read-only operation implied by 'search').

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, well-structured sentence that immediately communicates the tool's primary function. There is no redundant or filler content. The key terms 'weighted blend', 'vector similarity', and 'full-text search' are all high-signal and front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is concise but under-specified for a tool with 10 parameters and no schema-level descriptions. Given the existence of an output schema, the return format is covered, but the description does not explain how to configure weights, metrics, or filtering. It also fails to differentiate from sibling tools. This makes it adequate but with clear gaps in a complex context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, meaning the description adds no parameter-level detail. With 10 parameters, including k, metric, vector_weight, and return_columns, the description only mentions the core inputs (query_embedding, text_column, etc.) implicitly. It does not explain what any parameter means or how to use them, leaving the agent to rely solely on parameter names, which is insufficient.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states that this tool ranks rows using a weighted blend of vector similarity and full-text search. This distinguishes it from sibling tools like similarity_search, which likely only handles vector similarity. The verb 'Rank' and the resources 'rows' and 'Postgres full-text search' are specific and informative.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies use for hybrid retrieval scenarios but does not explicitly state when to use this tool over a pure vector search (similarity_search) or full-text search alone. No exclusions or alternative recommendation is provided. This is acceptable but not explicit, matching 'implied usage' rather than clear guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/mittalpk/mcp-server-pgvector'

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