Skip to main content
Glama

query_graph_global

Answer a corpus-wide question by Map-Reduce over community summaries: every selected community is summarised against the query, then the partial answers are reduced into one response that lists the communities it drew on. Use it for themes, trends and overviews across a whole corpus; for pinpoint lookups or single-document questions use query_graph instead. Returns: the reduced answer with the community summaries and the source evidence behind them. Raises QUERY_CAPACITY when the server is at its active-query limit — retry shortly.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "query_graph_global"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesThe natural-language question about the corpus as a whole (max 4000 characters).
workspace_idNoWorkspace that owns the graph, 1–63 chars of [a-z0-9-]. Use the same id for every operation on one corpus. Defaults to "default".default
community_levelNoWhich communities to summarise: "leaf" (default) for all terminal communities, or an integer to use exactly that level of the hierarchy (higher levels are broader and cheaper).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / community_level / description
      Added value: +"Which communities to summarise: \"leaf\" (default) for all terminal communities, or an integer to use exactly that level of the hierarchy (higher levels are broader and cheaper)."
    • addedInput schema / properties / query / description
      Added value: +"The natural-language question about the corpus as a whole (max 4000 characters)."
    • addedInput schema / properties / workspace_id / description
      Added value: +"Workspace that owns the graph, 1–63 chars of [a-z0-9-]. Use the same id for every operation on one corpus. Defaults to \"default\"."
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does so well: it discloses the Map-Reduce execution model, what the response contains (reduced answer, community summaries, source evidence), and a specific failure mode (QUERY_CAPACITY) with retry guidance. It also adds that higher community levels are broader and cheaper.

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 three sentences with no wasted text. Usage guidance is front-loaded after the core purpose, and the return/error information follows in an efficient order.

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

Completeness5/5

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

For a three-parameter query tool with no annotations and no output schema, the description covers purpose, alternative routing, return shape, and a relevant error condition. Nothing an agent needs to select or invoke it correctly is missing.

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

Parameters3/5

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

Schema description coverage is 100%, so both query and community_level meaning are already documented in the schema. The description reinforces that communities are 'selected' and that levels trade breadth for cost, but adds little beyond the schema's own explanations. Baseline 3 is appropriate when structured fields do the heavy lifting.

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 uses a specific verb and resource: 'Answer a corpus-wide question by Map-Reduce over community summaries.' It distinguishes itself from the sibling tool query_graph by scope and explicitly names query_graph as the alternative for pinpoint or single-document questions.

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

Usage Guidelines5/5

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

It states exactly when to use it ('themes, trends and overviews across a whole corpus') and when not to use it ('for pinpoint lookups or single-document questions use query_graph instead'). The routing condition is explicit and requires no inference.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources