myAImemory mcp
An MCP tool that synchronizes user preferences, personal details, and code standards across multiple Claude interfaces, allowing users to maintain consistent personalized AI interactions without repeating themselves.
An MCP tool that synchronizes user preferences, personal details, and code standards across multiple Claude interfaces, allowing users to maintain consistent personalized AI interactions without repeating themselves.
Tired of repeating yourself to Claude every time you start a new chat? myAI Memory Sync is a game-changing MCP tool that seamlessly synchronizes your preferences, personal details, and code standards across ALL your Claude interfaces! Just update once, and your changes instantly appear everywhere - from Claude Desktop to Claude Code, Windsurf, and Claude.ai web. With our cutting-edge caching system, memory-related queries are up to 2000x faster! Stop wasting tokens on repetitive instructions and enjoy a truly personalized AI experience.
While several excellent memory tools exist for AI systems, myAImemory-mcp serves a specific purpose as a Model Context Protocol (MCP) tool:
Tool | Primary Focus | Privacy Model | Integration | Unique Strength |
---|---|---|---|---|
myAImemory-mcp | User preferences across Claude interfaces | Local-first, no data sent to external servers | Claude-specific MCP | Cross-platform synchronization with high-performance caching |
Graphiti | Temporal knowledge graphs | Database-dependent | General agent framework | Temporal awareness in knowledge representation |
Letta/MemGPT | Stateful agent framework | Server-based | Multi-model support | Complete agent architecture |
Mem0 | Personalized AI interactions | API-based | Multi-platform | Multi-level memory hierarchy |
Memary | Human-like memory for agents | Graph database | Agent-focused | Human memory emulation |
Cognee | Reliable memory for AI apps | Multiple storage options | Data pipeline focused | Extensive data source integration |
Key Advantages of myAImemory-mcp: - Privacy-First: All data remains on your device, no personal information sent to external servers - Performance: Leverages Claude's caching capabilities for dramatic speed improvements - Simplicity: Natural language updates to your preferences across all Claude interfaces - MCP Integration: Purpose-built as a Claude MCP for seamless integration
# Clone repository
git clone https://github.com/Jktfe/myaimemory-mcp.git
cd myaimemory-mcp
# Install dependencies
npm install
# Build TypeScript code
npm run build
# Start MCP server
./start-memory-sync.sh
For a simpler approach that does not require running an MCP server, you can use the standalone sync script:
# One-time sync of all memory files
node sync-memory.js
This script will: - Read from your "myAI Master.md" file - Update all CLAUDE.md files in your projects - Update your Windsurf memory settings - All without storing sensitive information in the git repository
.gitignore
to ensure sensitive files remain privateThen in Claude, just say:
You: Use myAI Memory to remember I prefer TypeScript over JavaScript
Claude: ✅ Added to your Coding Preferences! I'll remember you prefer TypeScript over JavaScript.
Install from npm:
npm install -g myai-memory-sync
Start the server:
myai-memory-sync
Clone and build from source:
git clone https://github.com/Jktfe/myaimemory-mcp.git
cd myaimemory-mcp
npm install
npm run build
npm start
Build and run with Docker:
docker build -t myai-memory-sync .
docker run -v myai-memory:/app/data -p 3000:3000 myai-memory-sync
Add this to your claude_desktop_config.json
:
{
"mcpServers": {
"myai-memory-sync": {
"command": "npx",
"args": [
"-y",
"myai-memory-sync"
],
"env": {
"TEMPLATE_PATH": "/path/to/custom/template.md",
"ENABLE_ANTHROPIC": "true",
"ANTHROPIC_API_KEY": "your-api-key-here"
}
}
}
}
@Jktfe/myaimemory-mcp
In Windsurf, add to your .codeium/config.json
:
{
"mcp": {
"servers": {
"myai-memory-sync": {
"command": "npx",
"args": [
"-y",
"myai-memory-sync"
]
}
}
}
}
For HTTP transport instead of stdio:
# Start HTTP server on port 3000
npm run start:http
# Or specify a custom port
PORT=8080 npm run start:http
Create a .env
file with the following options:
# Basic configuration
DEBUG=true # Enable debug logging
TEMPLATE_PATH=./data/template.md # Custom template location
# Platform-specific paths
WINDSURF_MEMORY_PATH=~/.codeium/windsurf/memories/global_rules.md
CLAUDE_PROJECTS_PATH=~/CascadeProjects
# Performance optimization
ENABLE_ANTHROPIC=true # Enable Anthropic API integration
ANTHROPIC_API_KEY=your-api-key # Your Anthropic API key
ENABLE_PROMPT_CACHE=true # Enable prompt caching system
CACHE_TTL=300000 # Cache TTL in milliseconds (5 minutes)
# Claude web sync (optional)
CLAUDE_WEB_SYNC_ENABLED=false # Enable Claude.ai web synchronization
[email protected] # Your Claude.ai email
CLAUDE_WEB_HEADLESS=true # Run browser in headless mode
For best results, add this to your Claude system prompt:
Memory Integration Instructions:
When you receive a command that starts with "use myAI Memory to", you should:
1. Process the rest of the instruction as a memory management command
2. Try to determine the appropriate section to update based on the content
3. Use the myAI Memory Sync MCP to update your memory
4. Confirm the update with a brief acknowledgment
For example:
"use myAI Memory to remember I prefer dark mode"
→ Update the preferences section with dark mode preference
When asked questions about preferences or personal information, first check your memory via the myAI Memory Sync MCP. Always reference information from memory rather than making assumptions.
myAI Memory Sync uses a modular architecture with these key components:
PlatformSyncer
interface for each target platformThe system uses a structured markdown format to organize your preferences:
# myAI Memory
# User Information
## Use this information if you need to reference them directly
-~- Name: Your Name
-~- Location: Your Location
-~- Likes: Reading, Hiking, Technology
# General Response Style
## Use this in every response
-~- Style: Friendly and concise
-~- Use UK English Spellings: true
-~- Include emojis when appropriate: true
# Coding Preferences
## General Preference when responding to coding questions
-~- I prefer TypeScript over JavaScript
-~- Show step-by-step explanations
interface MemoryTemplate {
sections: TemplateSection[];
}
interface TemplateSection {
title: string;
description: string;
items: TemplateItem[];
}
interface TemplateItem {
key: string;
value: string;
}
interface PlatformSyncer {
sync(templateContent: string): Promise<SyncStatus>;
}
type PlatformType = 'claude-web' | 'claude-code' | 'windsurf' | 'master';
interface SyncStatus {
platform: PlatformType;
success: boolean;
message: string;
}
The myAI Memory Sync tool implements the Model Context Protocol (MCP) with the following functions:
Function | Description | Parameters |
---|---|---|
get_template |
Retrieves the full memory template | None |
get_section |
Retrieves a specific section | sectionName: string |
update_section |
Updates a specific section | sectionName: string, content: string |
update_template |
Replaces the entire template | content: string |
list_presets |
Lists available presets | None |
load_preset |
Loads a specific preset | presetName: string |
create_preset |
Creates a new preset | presetName: string |
sync_platforms |
Synchronizes across platforms | platform?: string |
list_platforms |
Lists available platforms | None |
Users can interact with the system through natural language commands:
You: Use myAI Memory to remember I prefer TypeScript over JavaScript
Claude: ✅ Added to your Coding Preferences! I'll remember you prefer TypeScript over JavaScript.
You: Use myAI Memory to load preset developer
Claude: ✅ Loaded developer preset! I'll now use your developer preferences.
Switch between different personas easily:
You: Use myAI Memory to list presets
Claude: Available presets: personal, work, developer
You: Use myAI Memory to load preset developer
Claude: ✅ Loaded developer preset!
When you need to fix synchronization issues across all platforms:
# Sync everything immediately
./emergency-sync.sh
# View all available commands
node dist/cli.js --help
# Process memory commands directly
node dist/cli.js --remember "remember I prefer dark mode"
# Start HTTP server for SSE transport
npm run start:http
# Start stdio server for MCP transport
npm run start
# Run in development mode with auto-reload
npm run dev
# Run in development mode with HTTP server
npm run dev:http
# Watch TypeScript compilation
npm run build:watch
# Run tests
npm test
# Run specific test
npm test -- -t "platformSync"
# Lint code
npm run lint
# Type check without emitting files
npm run typecheck
Our caching system delivers incredible performance improvements:
Operation | Without Cache | With Cache | Improvement |
---|---|---|---|
Memory Query | ~2000ms | ~1ms | 2000x |
Section Lookup | ~1600ms | ~0.8ms | 2000x |
Template Parse | ~120ms | ~0.1ms | 1200x |
Platform Sync | ~850ms | ~350ms | 2.4x |
We take your privacy seriously:
ls -la CLAUDE.md
./emergency-sync.sh
Verify platform paths in your .env
file
MCP Connection Failures
ps aux | grep myai-memory
Verify your Claude Desktop configuration file
Caching Issues
node dist/cli.js --clear-cache
node dist/cli.js --validate
Enable debug mode to see detailed logs:
DEBUG=true npm run start
Log files are stored in:
- Linux/macOS: ~/.local/share/myai-memory/logs/
- Windows: %APPDATA%myai-memorylogs
Contributions are welcome! Please feel free to submit a Pull Request.
git checkout -b feature/amazing-feature
)git commit -m 'Add some amazing feature'
)git push origin feature/amazing-feature
)We follow a standard Git workflow and CI process:
For more detailed documentation, see the Wiki.
API documentation is available in the /docs
directory:
# Generate API documentation
npm run docs
This project is licensed under the MIT License - see the LICENSE file for details.
Project Link: https://github.com/Jktfe/myaimemory-mcp
Made with ❤️ for the AI community