Skip to main content
Glama
stevepridemore

Graph-Memory

Build Session Context

graph_build_context
Read-only

Bundles graph health, pending work, recent additions, top hubs, contradictions, and optional topic neighbourhood into one call to reduce round trips at session start.

Instructions

Single tool call that bundles a session's worth of context: graph health, pending work, last dream run summary, recent additions, top knowledge hubs, unresolved contradictions, and (optionally) a topic neighbourhood. Use this at session start instead of running graph_stats / graph_query / graph_contradictions separately. Cuts 4-5 round trips to one.

Input Schema

NameRequiredDescriptionDefault
topicNoOptional topic to fetch a neighbourhood for (uses graph_query under the hood).
hub_countNoNumber of top knowledge hubs to include (default 5).
max_recentNoMax recent entities to list (default 15).
project_cwdNoOptional project directory for affinity scoring on the topic neighbourhood.
recent_daysNoWindow in days for 'recently added' entities (default 7).
include_contradictionsNoInclude unresolved contradictions (default true).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.2.2
  2. Removedv0.1.4
  3. First observedv1.0.0

TDQS

A4.6/5.0
Behavior4/5

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

The description adds value beyond the readOnlyHint annotation by detailing the specific data included in the bundled context. However, it does not disclose any additional behavioral traits such as performance implications or return size.

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: first states purpose, second gives usage guidance, third quantifies benefit. No redundant information, perfectly front-loaded.

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?

Given the tool's complexity (6 optional parameters, no output schema), the description adequately explains what is returned. However, it lacks details on the exact format or structure of the output, which would be helpful for the agent.

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?

Schema coverage is 100%, providing baseline value. The description adds context by explaining that parameters like topic and project_cwd are for optional neighbourhood fetching and affinity scoring, linking them to the overall bundle purpose. This adds some meaning beyond the schema's descriptions.

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 it bundles a session's worth of context, listing specific items like graph health, pending work, contradictions, etc. It also distinguishes itself from sibling tools by explicitly mentioning the individual tools it replaces (graph_stats, graph_query, graph_contradictions).

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 explicitly instructs to use the tool at session start instead of running separate tools, and quantifies the benefit as reducing round trips from 4-5 to 1. This provides clear when-to-use and alternative guidance.

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