A blazingly fast, local-first Knowledge Graph server that connects to Cursor IDE. Think of it as your personal AI memory that gets smarter as you code, without sending your data anywhere.
✨ What This Does
🚀 10-40x Faster than other knowledge graph solutions
High-performance Knowledge Graph MCP Server for Cursor IDE with local embeddings, advanced search, and comprehensive security features
🔒 100% Local - Your code never leaves your machine (no API keys needed!)
🧠 Smart Memory - Remembers your conversations, decisions, and code patterns
⚡ Real-time - Syncs instantly with Cursor IDE as you work
🔍 Powerful Search - Find anything across your entire codebase and conversations
🛡️ Secure - Built-in authentication and input validation
🚀 Quick Start (10 Minutes to Running)
Prerequisites
Rust (we'll install this for you)
macOS, Linux, or Windows
Cursor IDE (recommended) or any MCP-compatible editor
Step 1: Get the Code
git clone https://github.com/Nonymaus/cursor-kg.git
cd cursor-kg
Step 2: Install Rust (if you don't have it)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source ~/.cargo/env
Step 3: Build and Run
# Build the server (takes 2-3 minutes first time)
cargo build --release
# Start the server
cargo run --release
That's it! The server is now running on http://localhost:8360 🎉
🔧 Connect to Cursor IDE
Automatic Setup (Recommended)
# This creates the config file for you
echo '{
"mcpServers": {
"cursor-kg": {
"url": "http://localhost:8360/sse"
}
}
}' > ~/.cursor/mcp.json
In Cursor, try asking: "What's in my knowledge graph?"
If it works, you'll see a response from the server! 🎉
⚙️ Configuration Options
All settings are in config.toml. Here are the most important ones:
# Basic Settings
[database]
filename = "knowledge_graph.db" # Where your data is stored
[embeddings]
model_name = "nomic-embed-text-v1.5" # AI model for understanding text
batch_size = 16 # How many texts to process at once
# Security (optional)
[security]
enable_authentication = false # Set to true for API key protection
api_key = "" # Your secret key (if auth enabled)
rate_limit_requests_per_minute = 60 # Prevent spam
# Performance
[memory]
max_cache_size_mb = 128 # How much RAM to use for caching
💡 Tip: The defaults work great for most people. Only change these if you know what you're doing!
🎮 How to Use It
Basic Commands
# Start the server
cargo run --release
# Start with debug info (if something's wrong)
RUST_LOG=debug cargo run --release
# Run on a different port
MCP_PORT=9000 cargo run --release
# Check if it's working
curl http://localhost:8360/health
# Should return: {"status":"ok"}
What You Can Do
Once connected to Cursor, you can:
💬 Ask Questions
"What did we discuss about the authentication system?"
"Show me all the functions related to database queries"
"What are the main components of this project?"
📝 Add Information
"Remember that we decided to use SQLite for the database"
"Add this code pattern to the knowledge graph"
"Store this meeting summary"
🔍 Search & Analyze
"Find similar code patterns"
"What are the dependencies between these files?"
"Show me the project structure"
Advanced Usage
🔒 Enable Security (for production):
# In config.toml
[security]
enable_authentication = true
api_key = "your-secret-key-here"
🐳 Run with Docker:
docker build -t cursor-kg .
docker run -p 8360:8360 cursor-kg
📊 Monitor Performance:
# Check server stats
curl http://localhost:8360/metrics
🚨 Troubleshooting
Server Won't Start
# Check if port is already in use
lsof -i :8360
# Try a different port
MCP_PORT=8361 cargo run --release
# Check for errors
RUST_LOG=debug cargo run --release
上次檢查時間:2026-10-28。 High-performance Knowledge Graph MCP Server for Cursor IDE with local embeddings, advanced search, and comprehensive security features