Skip to main content
Glama
guerinjeanmarc

Neo4j GraphRAG MCP Server

Search-Augmented Cypher Query

search_cypher_query
Read-onlyIdempotent

Run custom Cypher queries that leverage Neo4j vector and fulltext search indexes for advanced retrieval, filtering, and graph traversal in GraphRAG applications.

Instructions

Execute a Cypher query that uses vector and/or fulltext search indexes.

This powerful tool allows you to:

  1. Use vector search ($vector_embedding) and/or fulltext search ($fulltext_text) in Cypher

  2. Post-filter large result sets (fetch 100-1000, filter with WHERE)

  3. Combine search with graph traversal

  4. Aggregate over search results

Example:

search_cypher_query(
    cypher_query='''
        CALL db.index.vector.queryNodes('chunk_embedding_vector', 500, $vector_embedding)
        YIELD node, score
        WHERE score > 0.75
        MATCH (node)-[:BELONGS_TO]->(d:Document)
        WHERE d.year >= 2020
        RETURN node.chunkId, d.title, score
        ORDER BY score DESC
        LIMIT 20
    ''',
    vector_query="student requirements"
)

Placeholders:

  • $vector_embedding: Replaced with embedding vector

  • $fulltext_text: Replaced with text string for fulltext

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsNoAdditional parameters for the Cypher query.
cypher_queryYesCypher query using $vector_embedding and/or $fulltext_text placeholders.
vector_queryNoText query to embed for vector search. Use $vector_embedding placeholder in Cypher.
fulltext_queryNoText query for fulltext search. Use $fulltext_text placeholder in Cypher.
Behavior4/5

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

The annotations already declare readOnlyHint=true and destructiveHint=false, so the safety profile is covered. The description adds meaningful behavioral context beyond annotations by explaining placeholder substitution (e.g., $vector_embedding replaced with embedding vector) and typical fetch sizes (100-1000). It also describes post-filtering behavior with WHERE. This extra detail is valuable and not redundant with the annotations.

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

Conciseness4/5

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

The description is well-structured with a bulleted list, an example, and a placeholder section. It is somewhat long due to the example, but every section serves a purpose. The front-loading of the core statement is good, and the example is necessary for a complex tool. It is concise enough given the tool's complexity, but not as tight as a two-sentence description.

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

Completeness4/5

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

Despite having no output schema, the description compensates with a rich example that shows the return shape and usage patterns. It covers the main combinations (vector/fulltext, post-filtering, traversal, aggregation) and the placeholder mechanism. Minor gaps exist, such as not explaining the 'params' object's possible contents or behavior when both vector and fulltext are used simultaneously, but overall it is sufficiently complete for a 4-parameter tool.

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

Parameters4/5

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

The schema covers all parameters, so the baseline is 3. The description adds semantic value by explaining how the placeholders in cypher_query relate to the vector_query and fulltext_query parameters, including the exact replacement behavior. It also demonstrates usage via the example. However, the 'params' object is not elaborated beyond its schema description, so the added value is not maximal.

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 the tool executes a Cypher query enhanced with vector and/or fulltext search indexes. It lists four specific capabilities and distinguishes itself from sibling tools like vector_search and fulltext_search by combining search with graph traversal, post-filtering, and aggregation. The verb 'execute' and resource 'Cyper query' are explicit, making the purpose unambiguous.

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

Usage Guidelines4/5

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

The description provides clear context on when to use the tool: when you need to post-filter large result sets, combine search with traversal, or aggregate over search results. However, it lacks explicit exclusions or direct comparisons to alternatives, such as 'use read_neo4j_cypher for non-search queries.' The example implies but does not explicitly state the alternative scenarios, so it falls short of a 5.

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/guerinjeanmarc/mcp-neo4j-graphrag'

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