-
Notifications
You must be signed in to change notification settings - Fork 9k
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Bug Report: Memory MCP Server - Schema Validation Error
Summary
All read operations (read_graph, search_nodes, open_nodes) fail with schema validation error when reading entities from JSONL format memory file. The server includes the type field in entity objects when reading from file, but the output schema does not allow this field.
Environment
- Server:
@modelcontextprotocol/server-memory - Version:
2025.11.25(latest available) - OS: Linux Ubuntu 24.04
- MCP Client: Cursor IDE
Steps to Reproduce
- Configure Memory MCP server with a JSONL format
memory.jsonfile - File contains entities with structure:
{"type":"entity","name":"...","entityType":"...","observations":[...]} - Call any read operation:
mcp_memory_read_graphmcp_memory_search_nodesmcp_memory_open_nodes
- All operations fail with the same error
Expected Behavior
Read operations should return entities without the type field, as entities are already separated in the response structure (data.entities vs data.relations).
Actual Behavior
All read operations return error:
{
"error": "MCP error -32602: Structured content does not match the tool's output schema: data.entities[0] should NOT have additional properties"
}No partial data is returned - the response contains only the error field.
Technical Details
- File format: JSONL (newline-delimited JSON)
- Total lines: 538
- Entities: 206
- Relations: 332
- Entity schema in file:
{type, name, entityType, observations}(4 fields) - Expected entity schema in output:
{name, entityType, observations}(3 fields, notype)
The type field is necessary in the file to distinguish entities from relations, but should be stripped when preparing the response.
Workaround
- Read data directly from
memory.jsonfile using file I/O - Write operations (
create_entities,add_observations, etc.) work correctly - Only read operations are affected
Additional Information
- The file structure is valid and can be read successfully using direct file access
- The issue appears to be in the server's schema validation logic
- Cache cleared (
npm cache clean --force) but issue persists - Issue occurs with latest server version (2025.11.25)
Error Code
MCP error -32602 - Invalid params / Schema validation error
vasilistotskas and scholzie
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working