A vibe-coded memory management system with RAG capabilities for Claude via the Model Context Protocol (MCP). SimpleMem is an MCP server that provides persistent memory storage and retrieval for Claude and other MCP clients. It combines traditional file-based storage with modern RAG (Retrieval-Augmented Generation) capabilities, including semantic search and automatic relationship discovery. Think
Add this skill
npx mdskills install jcdickinson/simplememWell-documented MCP server providing persistent memory with semantic search and RAG capabilities
1# SimpleMem23A vibe-coded memory management system with RAG capabilities for Claude via the Model Context Protocol (MCP).45> ⚠️ **Warning**: This project is completely vibe-coded. It works, but don't look too closely at the implementation details. The code was written by an AI having a good time, not by someone following best practices.67## What is SimpleMem?89SimpleMem is an MCP server that provides persistent memory storage and retrieval for Claude and other MCP clients. It combines traditional file-based storage with modern RAG (Retrieval-Augmented Generation) capabilities, including semantic search and automatic relationship discovery.1011Think of it as Claude's personal notebook that never forgets and can find connections between ideas automatically.1213## Features1415- 📝 **Persistent Memory Storage**: Store and retrieve memories with rich metadata16- 🔍 **Semantic Search**: Find memories using natural language queries17- 🔗 **Automatic Relationship Discovery**: Semantic backlinks connect related memories18- 🏷️ **Tag System**: Organize memories with flexible tagging19- 🎯 **Vector Embeddings**: Powered by Voyage AI for high-quality semantic understanding20- 📊 **DuckDB Backend**: Fast, efficient storage with vector similarity search21- 🔧 **MCP Protocol**: Seamless integration with Claude and other MCP clients2223## Quick Start2425### Prerequisites2627- Go 1.21+28- A Voyage AI API key (see Configuration section below)2930### Installation3132#### Option 1: Download Pre-built Binaries3334Download the latest release for your platform from [GitHub Releases](https://github.com/jcdickinson/simplemem/releases):3536- **Linux AMD64**: `simplemem-vX.X.X-linux-amd64.tar.gz`3738Extract and place the binary in your PATH.3940#### Option 2: Build from Source4142```bash43# Clone the repository44git clone https://github.com/jcdickinson/simplemem45cd simplemem4647# Install dependencies48just deps4950# Build the binary51just build52```5354#### Option 3: Nix5556If you have Nix with flakes enabled:5758```bash59# Run directly from GitHub60nix run github:jcdickinson/simplemem6162# Or clone and run locally63git clone https://github.com/jcdickinson/simplemem64cd simplemem65nix run6667# Install to profile68nix profile install github:jcdickinson/simplemem6970# Run in development shell71nix develop72```7374### Configuration7576SimpleMem uses TOML-based configuration with flexible options for API keys and settings.7778#### Configuration File7980Create a `config.toml` file (see `config.toml.example` for reference):8182```toml83[voyage_ai]84model = "voyage-3.5"85rerank_model = "rerank-lite-1"8687api_key = { "path" = "~/.config/simplemem/voyage_api_key.txt" }88# OR89api_key = "api-key-here"90```9192#### Environment Variables9394You can also configure using environment variables:9596```bash97export SIMPLEMEM_VOYAGE_AI_API_KEY="your-api-key"98export SIMPLEMEM_VOYAGE_AI_MODEL="voyage-3.5"99export SIMPLEMEM_VOYAGE_AI_RERANK_MODEL="rerank-lite-1"100```101102#### Configuration Options103104- **Custom config file**: Use `--config path/to/config.toml`105- **Database path**: Use `--db path/to/database.db` (can also be set in config)106- **API key sources**: File path (recommended) or direct value107- **Multiple configs**: Different configs for different projects108109### Usage110111#### As an MCP Server112113Add to your MCP client configuration:114115```json116{117 "mcpServers": {118 "simplemem": {119 "command": "./simplemem",120 "args": [121 "--db",122 "path/to/your/database.db",123 "--config",124 "path/to/config.toml"125 ]126 }127 }128}129```130131#### Command Line Testing132133```bash134# Create a memory135just test-json '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"create_memory","arguments":{"name":"my-memory","metadata":{"title":"My First Memory","description":"A test memory","tags":{"category":"test","priority":"low"}},"content":"# Hello World\n\nThis is my first memory!"}},"id":1}'136137# Search memories (primary discovery method)138just test-json '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"search_memories","arguments":{"query":"hello world"}},"id":1}'139140# Read a specific memory141just test-json '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"read_memory","arguments":{"name":"my-memory"}},"id":1}'142```143144#### Testing Semantic Backlinks145146```bash147# Run comprehensive semantic backlinks test148just test-backlinks149150# Verify backlinks are working151just test-json '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"get_backlinks","arguments":{"name":"my-memory"}},"id":1}'152```153154## Available Tools (MCP)155156- **`create_memory`**: Create a new memory with metadata object and markdown content157- **`read_memory`**: Read a specific memory by name158- **`update_memory`**: Update existing memory metadata and content159- **`delete_memory`**: Remove a memory and all related data160- **`search_memories`**: Semantic search with optional tag filtering (primary discovery method)161- **`get_backlinks`**: Get memories related to a specific memory162- **`change_tag`**: Modify tags on memories163164> **Note**: `list_memories` has been temporarily removed to encourage efficient semantic search usage instead of token-heavy full listings.165166## Memory Format167168### API Structure (for create_memory/update_memory)169170```json171{172 "name": "my-memory-name",173 "metadata": {174 "title": "A Human-Readable Title",175 "description": "Brief description of the memory",176 "tags": {177 "category": "personal",178 "priority": "high",179 "status": "active"180 },181 "custom_field": "any_value",182 "version": "1.0"183 },184 "content": "# Memory Content\n\nYour memory content in **Markdown** format.\n\n- Clean markdown without frontmatter\n- Links to [[other-memories]]\n- Whatever you need!"185}186```187188### On-Disk Storage189190Memories are stored as YAML frontmatter + Markdown:191192```markdown193---194title: A Human-Readable Title195description: Brief description of the memory196tags:197 category: personal198 priority: high199 status: active200custom_field: any_value201version: "1.0"202created: 2025-01-24T12:00:00Z203modified: 2025-01-24T12:00:00Z204---205206# Memory Content207208Your memory content in **Markdown** format.209210- Clean markdown without frontmatter211- Links to [[other-memories]]212- Whatever you need!213```214215## Development216217### Prerequisites218219- [Just](https://github.com/casey/just) command runner220221### Common Commands222223```bash224# Show available commands225just226227# Run tests (when they exist)228just test229230# Format code231just fmt232233# Run with verbose logging234just run-verbose235236# Test semantic backlinks functionality237just test-backlinks238239# Clean up build artifacts240just clean241```242243### Debug Testing244245For rapid development iteration:246247```bash248# Test any JSON-RPC call with custom database249just test-json '<json>' /tmp/test.db250251# Quick minimal test252just test-clean /tmp/debug.db253254# Build and test in one command255just build-test256```257258## Architecture259260- **Frontend**: MCP JSON-RPC 2.0 protocol server261- **Storage**: File-based memory storage with DuckDB backend262- **Search**: Voyage AI embeddings + vector similarity263- **Relationships**: Automatic semantic backlink discovery264- **Memory**: YAML frontmatter + Markdown content265266## Known Issues267268- No proper test suite (it's vibe-coded, remember?)269- Error handling could be more robust270- Some edge cases might crash things271- Documentation is whatever this README covers272- Database migrations? What are those?273274## Contributing275276This is a vibe-coded project, so contributions should match the energy:2772781. Make it work first2792. Make it work well second2803. Make it pretty... maybe later?2814. Tests are aspirational2825. If it breaks, fix it with more vibes283284## License285286LGPL 3.0 - Use it, modify it, vibe with it (but share improvements back to the community).287288## Credits289290- Built with love and caffeine291- Powered by [Voyage AI](https://voyageai.com) embeddings292- Uses [DuckDB](https://duckdb.org) for storage293- MCP integration via [mark3labs/mcp-go](https://github.com/mark3labs/mcp-go)294295---296297_"It works on my machine, and that machine has good vibes."_ ✨298
Full transparency — inspect the skill content before installing.