mcp-prose-memory runs as a stdio MCP server. Clients start it with npx mcp-prose-memory, then call the exposed tools over the MCP protocol.
Runtime flow
- The client starts the server process.
- The server exposes the
memoryandmemory_contexttools. - Each operation loads the current JSON memory file.
- Input is validated before any mutation.
- Mutations are written to a sibling temp file, synced, and renamed over the target file.
Atomic writes
Updates are written through temp-file replacement in the same directory as the target file. This keeps a partial write from replacing the real memory file if the process stops during the write. The temp file is created with mode0600, then renamed to the configured memory path after the write is synced.