Skip to content

fix: include outgoing relations in open_nodes#3332

Open
Limitless2023 wants to merge 1 commit into
modelcontextprotocol:mainfrom
Limitless2023:fix/memory-open-nodes-outgoing-relations
Open

fix: include outgoing relations in open_nodes#3332
Limitless2023 wants to merge 1 commit into
modelcontextprotocol:mainfrom
Limitless2023:fix/memory-open-nodes-outgoing-relations

Conversation

@Limitless2023

Copy link
Copy Markdown

Summary

Fix for issue #3137 - open_nodes returns empty relations array even when entities have outgoing relations.

Changes

  • Modified openNodes to return outgoing relations (where the entity is the from endpoint) in addition to relations between opened nodes
  • Updated tool description to reflect new behavior
  • Updated tests to match new expected behavior

Why

Previously, open_nodes only returned relations where both endpoints were in the requested node list. This made it impossible to traverse the graph from specific nodes without reading the entire graph.

Now, when you open a node, you also get its outgoing relations, enabling graph traversal.

Test

All tests pass (42/42)

When opening nodes in the knowledge graph, return outgoing
relations (where the entity is the 'from' endpoint) in addition
to relations between opened nodes. This allows traversing
the graph from specific nodes without needing to read the
entire graph.

Fixes modelcontextprotocol#3137
@cliffhall cliffhall added bug Something isn't working server-memory Reference implementation for the Memory MCP server - src/memory labels Apr 20, 2026
@BossChaos

This comment was marked as abuse.

@LuuOW LuuOW left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technical audit: Verified MCP server implementation for consistency with current SDK patterns.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working server-memory Reference implementation for the Memory MCP server - src/memory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants