memory_edge_search silently returns empty for partial UUIDs instead of matching or erroring #3

Closed
opened 2026-02-28 05:00:03 +00:00 by cal · 0 comments
Owner

Bug

memory_edge_search with from_id or to_id accepts partial UUIDs (e.g., e6158e53) without error but returns empty results, even when edges exist for the full UUID (e6158e53-af06-40f7-bfd1-32fc481a2b3f).

Steps to reproduce

  1. Store a memory → get ID e6158e53-af06-40f7-bfd1-32fc481a2b3f
  2. Create an edge from that memory
  3. memory_edge_search(from_id="e6158e53") → returns []
  4. memory_edge_search(from_id="e6158e53-af06-40f7-bfd1-32fc481a2b3f") → returns the edge

Expected behavior

Either:

  • Prefix match: treat partial IDs as prefixes and match (like git log abc123 matches commit abc12345...)
  • Error: return an error like "Invalid UUID format" or "No memory found for ID: e6158e53"

Why this matters

The memory-saver subagent uses short IDs from memory_store responses (e.g., e6158e53) when calling memory_relate and memory_edge_search. The silent empty response made it appear that edges weren't being created, when they actually were — memory_relate apparently does handle short IDs (or the agent had full IDs). The inconsistency between tools caused a misleading debugging session.

Recommendation

Prefix matching (git-style) would be the most ergonomic fix, applied consistently across memory_edge_search, memory_relate, memory_get, and memory_related.

## Bug `memory_edge_search` with `from_id` or `to_id` accepts partial UUIDs (e.g., `e6158e53`) without error but returns empty results, even when edges exist for the full UUID (`e6158e53-af06-40f7-bfd1-32fc481a2b3f`). ## Steps to reproduce 1. Store a memory → get ID `e6158e53-af06-40f7-bfd1-32fc481a2b3f` 2. Create an edge from that memory 3. `memory_edge_search(from_id="e6158e53")` → returns `[]` 4. `memory_edge_search(from_id="e6158e53-af06-40f7-bfd1-32fc481a2b3f")` → returns the edge ## Expected behavior Either: - **Prefix match**: treat partial IDs as prefixes and match (like `git log abc123` matches commit `abc12345...`) - **Error**: return an error like `"Invalid UUID format"` or `"No memory found for ID: e6158e53"` ## Why this matters The memory-saver subagent uses short IDs from `memory_store` responses (e.g., `e6158e53`) when calling `memory_relate` and `memory_edge_search`. The silent empty response made it appear that edges weren't being created, when they actually were — `memory_relate` apparently does handle short IDs (or the agent had full IDs). The inconsistency between tools caused a misleading debugging session. ## Recommendation Prefix matching (git-style) would be the most ergonomic fix, applied consistently across `memory_edge_search`, `memory_relate`, `memory_get`, and `memory_related`.
cal closed this issue 2026-02-28 05:57:13 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: cal/claude-memory#3
No description provided.