Skip to main content
graph is gated by graph. It exposes GraphRAG-style retrieval over a knowledge graph the server maintains, selected by an op. Servers advertise the ops they support in graph.ops.

Params

"local" | "global" | "drift" | "communities" | "neighbors"
required
The graph operation. MUST be one of the advertised graph.ops.
string
The natural-language query (for local, global, drift).
integer
Result count where applicable.
string | number
A node id (for neighbors).

Operations

local

Entity-centric retrieval: find the entities and relationships closest to the query and gather their neighbourhood. Returns hits.

global

Map-reduce over precomputed community summaries for corpus-wide, thematic “sensemaking” questions. Returns a summary and communities.

drift

Dynamic Reasoning and Inference over a Fuzzy Trace — blends local and global, following the graph as reasoning unfolds.

communities / neighbors

communities lists detected communities; neighbors expands the adjacency of a given node.

Result

Shapes depend on the op. Entity-centric ops (local, drift, neighbors) return hits with the same Hit shape as retrieve. Corpus-wide ops (global, communities) return a summary string and a communities array.
GraphRAG unifies local (entity) and global (thematic) retrieval under one method so a client can ask both “what connects X and Y?” and “what are the big themes?” without a second protocol.