Skip to main content
Glama

Get Related Memories

get_related_memories

Retrieve memories linked to a specific concept, including relationship details and direction filters. Use it to explore the knowledge graph around a memory.

Instructions

Get memories related to a given memory.

Returns related memories along with their relationship information. Use this to explore the knowledge graph around a specific concept.

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": {
      "memory_id": "<memory_id>"
    },
    "name": "get_related_memories"
  }
}

Input Schema

NameRequiredDescriptionDefault
directionNoDirection: 'outgoing' (from this memory), 'incoming' (to this memory), or 'both' (default)both
memory_idYesMemory ID to find relationships for
relation_typeNoFilter by relation type

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.8.0

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description must carry the behavioral burden; it implies a safe read ('Get', 'Returns') and states that relationship information is included in the response. It does not disclose error behavior for an unknown memory_id, whether traversal is recursive or one hop, pagination or result caps, or permission requirements.

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?

Three short sentences, front-loaded with the core action, and no filler. The second sentence slightly restates the first by re-mentioning related memories, but the relationship-information detail is additive.

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 simple three-parameter read tool with a fully documented schema and a declared output schema, the description covers what it does, what it returns at a high level, and a use case. Return-shape details are handled by the output schema, so remaining gaps (error semantics, traversal depth) are minor.

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%, including the direction enum values and the relation_type filter, so the schema already does the heavy lifting. The description adds no parameter-level meaning beyond the schema; the baseline of 3 is appropriate.

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

Purpose4/5

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

The description states a specific verb and resource ('Get memories related to a given memory') and clarifies the scope is one-hop relationship retrieval around that memory. It is clearly distinct from mutation siblings like link_memories or forget, though it doesn't explicitly name a sibling to contrast with.

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 line 'Use this to explore the knowledge graph around a specific concept' gives an implied usage context, but there is no explicit when-not guidance and no named alternative such as recall or list_memories. The agent must infer that this is the traversal tool rather than the broad search tool.

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