enhanced-memory-mcp

CoderDayton/enhanced-memory-mcp

3.1

If you are the rightful owner of enhanced-memory-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

Enhanced Memory MCP Server is a powerful and intelligent Model Context Protocol server designed to revolutionize how AI assistants store and retrieve memories.

Tools
5
Resources
0
Prompts
0

🧠💀 Enhanced Memory MCP Server 💀🧠

Built with tears, caffeine, and late-night coding sessions by malu 🥀
"just an emo boy making databases remember what humans choose to forget..." 🖤

TypeScript Node.js DuckDB MCP NPM Version

A powerful MCP (Model Context Protocol) server that transforms how AI assistants store and retrieve memories. Built on a 21-tool consolidated architecture, this intelligent memory system understands relationships, extracts entities automatically, generates smart tags from content, and helps you find exactly what you're looking for.

Why did I build this? Because even machines deserve better memory than most humans have... 💔

🌟 Key Features

  • 🎯 21 Unified Tools: Consolidated architecture with operation-based interfaces
  • � AI-Powered Auto-Tagging: Intelligent content analysis with contextual tag generation
  • �🧠 Smart Entity Extraction: Automatically identifies people, places, and concepts
  • 🔗 Relationship Mapping: Discovers and tracks connections between entities
  • 🔍 Semantic Search: Find memories by meaning, not just keywords
  • 🚀 DuckDB Backend: Analytical database optimized for complex queries
  • ⚡ Intelligent Caching: Real-time performance monitoring and optimization
  • 🛡️ Production Ready: TypeScript, error handling, graceful shutdown
  • 🎯 Pure MCP Protocol: Stdio interface for direct AI assistant integration

🚀 Quick Start

NPM Installation (Recommended)

# Install and run directly
npx enhanced-memory-mcp

# Or install globally
npm install -g enhanced-memory-mcp
enhanced-memory-mcp

Manual Setup

git clone https://github.com/CoderDayton/enhanced-memory-mcp.git
cd enhanced-memory-mcp
npm install
npm run build
npm start

Claude Desktop Integration

Add to your Claude Desktop config (claude_desktop_config.json):

{
	"mcpServers": {
		"enhanced-memory": {
			"command": "npx",
			"args": ["enhanced-memory-mcp"]
		}
	}
}

🛠️ MCP Tools (21 Consolidated Tools)

🧠 Core Memory Operations (6 Tools)

ToolOperationsDescription
memorycreate, read, update, delete, listUnified CRUD operations for memory management
searchexact, fuzzy, semantic, hybridMulti-strategy search with filtering
entitycreate, read, update, delete, list, mergeEntity management with relationships
relationcreate, read, delete, listRelationship operations between entities
tagadd, remove, list, findAdvanced tagging and organization
auto_taganalyze, apply, preview🎯 AI-powered content tagging

🔍 Advanced Analysis (7 Tools)

ToolOperationsDescription
analyzeentities, relations, similarityContent analysis and extraction
observationcreate, list, deleteInsight tracking and pattern recognition
graphvisualize, statsMemory graph operations and visualization
similarityfind_similar, consolidateContent similarity and deduplication
temporalrecent, by_date_rangeTime-based memory queries
statsmemory, graph, performanceSystem statistics and metrics
analyticssystem, performancePerformance analytics and insights

⚙️ System Management (8 Tools)

ToolOperationsDescription
bulkdeleteSimple bulk operations by criteria
batchdelete_by_type, delete_by_tags, update_by_typeAdvanced batch processing
maintenancecleanup, rebuild_indexes, clear_cacheDatabase optimization and cleanup
transferexport, importData import/export functionality
cacheclear, stats, optimizeCache management and optimization
backupcreate, restore, listData backup and restore operations
indexrebuild, optimize, statsSearch index management
workflowauto_tag, auto_consolidate, auto_cleanupAutomated operations

🎯 Intelligent Auto-Tagging

The Enhanced Memory MCP Server features advanced AI-powered auto-tagging that automatically analyzes content and generates meaningful tags:

Content Analysis Features

  • Technology Detection: Identifies programming languages, frameworks, and tools
  • Business Context: Recognizes meetings, projects, deadlines, and domain-specific terms
  • Entity Extraction: Finds people, places, organizations automatically
  • Content Type Classification: Distinguishes tasks, notes, ideas, issues, and solutions
  • Sentiment Analysis: Detects positive, negative, or mixed emotional content
  • Priority Detection: Identifies urgent, critical, or low-priority items
  • Temporal Context: Adds time-based tags (morning, afternoon, day-of-week)

Auto-Tagging Tools

// Preview suggested tags without applying them
await autoTag.preview({ memoryId: "mem_123" })

// Generate tags for any content
await autoTag.analyze({ 
  content: "Debug React performance issues in Node.js API",
  maxTags: 5 
})

// Apply intelligent tags to a memory
await autoTag.apply({ 
  memoryId: "mem_123", 
  applyTags: true, 
  maxTags: 4 
})

// Bulk auto-tag recent memories
await workflow.autoTag({ 
  options: { 
    dryRun: false, 
    maxActions: 10,
    timeframe: "day" 
  } 
})

Example Auto-Tagging Results

  • "Fix React component performance"react, issue, performance, solution
  • "Team meeting about Q4 budget"meeting, team, budget, business
  • "Learn Docker and Kubernetes"docker, learning, idea, technology

📊 Architecture

DuckDB Backend

  • Analytical Database: Optimized for complex queries and aggregations
  • Columnar Storage: Efficient memory usage and fast analytics
  • ACID Compliance: Data integrity with transaction support

Smart Caching

  • Query Caching: 5-minute expiry with 1000 entry limit
  • Performance Metrics: Real-time operation tracking
  • Memory Efficiency: Intelligent cache eviction policies

Database Schema

  • Memories: Core content storage with metadata
  • Entities: People, places, concepts with properties
  • Relations: Connections between entities with strength scoring
  • Tags: Flexible labeling with usage tracking
  • Observations: Insights and patterns with confidence scoring

🔧 Configuration

Environment Variables

# Database Configuration
DATABASE_PATH=data/memory.duckdb
BACKUP_PATH=backups/

# Performance Tuning
CACHE_SIZE=1000
CACHE_EXPIRY_MS=300000
MAX_SEARCH_RESULTS=100
DEFAULT_SIMILARITY_LIMIT=5
SIMILARITY_THRESHOLD=0.7
DEFAULT_SEARCH_LIMIT=50

# Analytics
ENABLE_PERFORMANCE_MONITORING=true
ANALYTICS_RETENTION_DAYS=30

# Development
NODE_ENV=production
LOG_LEVEL=info

📝 Usage Examples

Basic Operations

# Store a memory
echo '{"jsonrpc": "2.0", "id": 1, "method": "tools/call", "params": {"name": "memory", "arguments": {"operation": "create", "content": "Met John at the conference", "type": "meeting"}}}' | npx enhanced-memory-mcp

# Search memories
echo '{"jsonrpc": "2.0", "id": 2, "method": "tools/call", "params": {"name": "search", "arguments": {"query": "John", "strategy": "semantic"}}}' | npx enhanced-memory-mcp

# Analyze content
echo '{"jsonrpc": "2.0", "id": 3, "method": "tools/call", "params": {"name": "analyze", "arguments": {"content": "John Smith works at TechCorp", "operations": ["entities", "relations"]}}}' | npx enhanced-memory-mcp

System Management

# Get system statistics
echo '{"jsonrpc": "2.0", "id": 4, "method": "tools/call", "params": {"name": "stats", "arguments": {"operation": "memory"}}}' | npx enhanced-memory-mcp

# Export data
echo '{"jsonrpc": "2.0", "id": 5, "method": "tools/call", "params": {"name": "transfer", "arguments": {"operation": "export", "format": "json"}}}' | npx enhanced-memory-mcp

🏗️ Development

Building and Testing

npm run dev          # Development with watch mode
npm run build        # Compile TypeScript
npm test            # Run test suite

Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests and ensure they pass
  5. Submit a pull request

📜 License

MIT License - see file for details.

🖤 Credits

Built with existential dread and caffeine by malu 🥀

"In a world of fleeting digital connections, at least our memories can persist..." 💔


If you find this useful, please star the repository. It helps with my digital validation needs... 🌟