memory-mcp-server

MCP.Pizza Chef: hpkv-io

The Memory MCP Server is a Model Context Protocol server that enables long-term memory for large language models (LLMs) within the Cursor IDE. It allows AI assistants to remember project details, user preferences, and past interactions across sessions, improving reliability by reducing hallucinations and repeated mistakes. This server integrates with HPKV for persistent storage, enhancing AI coding workflows with contextual continuity and memory retention.

Use This MCP server To

Remember project structures and coding conventions across sessions Recall user preferences for coding style and patterns Reference previous explanations and design decisions Prevent AI from hallucinating non-existent code or functions Avoid repeating previously failed coding approaches Enhance AI coding assistants with persistent memory Improve reliability of AI suggestions in IDEs

README

Memory MCP Server - Cursor Rules

This repository contains the Cursor rule document for integrating the HPKV Memory MCP Server with Cursor IDE. The Memory MCP Server provides long-term memory capabilities for LLMs in Cursor, allowing AI assistants to remember conversations across sessions.

What is this?

The Memory MCP Server implements the Model Context Protocol (MCP) to give LLMs true long-term memory. This rule document enables Cursor IDE to:

  • Remember project structures and conventions across sessions
  • Recall user preferences for coding style and patterns
  • Reference previous explanations and decisions
  • Avoid hallucinating non-existent code and functions
  • Stop suggesting previously failed approaches

In short, it makes AI coding assistants in Cursor much more reliable by giving them access to persistent memory.

Adding to Cursor IDE

  1. Create a free HPKV account and create an API Key in Dashboard.

  2. Edit your mcp.json file:

{
  "mcpServers": {
    "hpkv-memory-server": {
      "command": "npx",
      "args": ["mcp-remote", "https://memory-mcp.hpkv.io/sse"]
    }
  }
}
  1. After adding the Memory MCP Server, you'll be prompted to login to your HPKV account. After that you can select the API key you generated.

  2. Add the memory cursor rule to your project and set the rule type to Always.

Cursor Rule Document

The memory_tool_usage_guide.mdc file contains the rules that instruct Cursor's AI how to properly use the memory tools. It includes:

  • Guidelines for when to search memory before responding
  • Patterns for storing important information
  • Best practices for memory retrieval
  • Naming conventions for organizing memories

OAuth Troubleshooting

In certain situations, mcp-remote might have trouble refreshing your token and it consitantly generates new Client IDs that lead to the loop of trying to register a new Client ID, openning API Key selection page and goingback to generating a new Client ID. To fix this, disable the MCP server in Cursor, kill all mcp-remote processes and clear the .mcp-auth folder with a command similar to pkill -f mcp-remote && rm -rf ~/.mcp-auth and then re-enable it in Cursor. This should fix any authentication issue you were experiencing.

Learn More

For more information, check out our blog post about Memory MCP and the HPKV documentation.

memory-mcp-server FAQ

How do I integrate the Memory MCP Server with Cursor IDE?
Create a free HPKV account, generate an API key, and configure your mcp.json file with the server details.
What benefits does long-term memory provide for AI coding assistants?
It enables the AI to remember past sessions, user preferences, and project context, reducing errors and improving suggestion relevance.
Is the Memory MCP Server compatible with multiple LLM providers?
Yes, it supports OpenAI, Anthropic Claude, and Google Gemini models through the MCP standard.
How does the Memory MCP Server prevent AI hallucinations?
By referencing persistent memory of actual project data and past interactions, it avoids suggesting non-existent code or functions.
Can I customize what the Memory MCP Server remembers?
Yes, you can configure which project data and user preferences are stored and recalled.
What is required to start using the Memory MCP Server?
You need an HPKV account, an API key, and to update your MCP configuration in Cursor IDE.
Does the Memory MCP Server support multi-session memory?
Yes, it is designed to persist memory across multiple coding sessions for continuity.
How secure is the data stored by the Memory MCP Server?
Data is stored securely via HPKV with scoped access, ensuring privacy and security.