
Memograph
io.github.Indhar01Published by GitHub account Indhar01v0.4.0Updated Oct 27, 2026
Graph-based memory system for LLMs with knowledge graphs and semantic search.
Overview
Turns a folder of markdown notes into a persistent knowledge graph that an assistant can search, read, link and update as long-term memory.
- What you can do
- Search and retrieve memories with hybrid keyword, semantic and graph retrieval, plus context windows for prompts
- Create, import, read, list, update and delete memories in a markdown vault
- Link memories and traverse the wikilink graph, including path finding between notes
- Inspect vault statistics and analytics
- Run autonomous auto-save hooks that capture conversation context into the vault
- Bulk-create memories and configure autonomous mode
- When to use it
- Useful when you want an assistant to remember decisions and context across conversations, or to search a large personal or team note collection by meaning rather than exact wording. Best for people who already keep notes as markdown files and want them indexed locally.
- Requirements
- Runs locally over stdio from the PyPI package memograph (uvx or pip install). Requires MEMOGRAPH_VAULT, the path to the vault directory, which is created if missing. Optional MEMOGRAPH_PROVIDER and MEMOGRAPH_MODEL select an LLM for AI-generated answers; ANTHROPIC_API_KEY, OPENAI_API_KEY or a local Ollama server (OLLAMA_HOST) are needed only for those providers or extras.
Installation
In SourceWeft
- Open Memograph in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
MemoGraph 🧠
[PyPI version] [Python Version] [License] [MCP Registry] [MCP] [Code style: ruff] [pre-commit] [Type checked: mypy] [Tests] [Code Quality]
MemoGraph turns a folder of markdown notes into a queryable, AI-ready knowledge graph. It solves the LLM memory problem — your AI assistants forget last Tuesday's decision, can't find a related note across two projects, and re-derive the same insight again and again — by giving them a persistent, navigable, attribution-friendly memory layer that lives in plain markdown files you control.
You write notes the way you already do. MemoGraph indexes them, builds a graph from [[wikilinks]], ranks them by salience, and serves them back to your LLM (or your team) on demand.
⚡ Try it in 60 seconds
That's it. The quickstart command drops a small, interconnected sample vault on your disk (15 notes about Python development, with real wikilinks between them), ingests it, and runs three live demo queries so you can see the graph + hybrid retrieval working before you decide whether to commit. Try this query in particular:
The vault contains a note titled FastAPI dependencies (about Depends(...)) — the words "dependency" and "injection" never appear in any note's title. MemoGraph still finds it, because hybrid retrieval understands "dependency injection" semantically and the wikilink graph stitches related notes together. That's the product, demonstrated in one query.
Re-run memograph quickstart --force any time to reset to a fresh demo. When you're ready, point MemoGraph at your real notes: memograph --vault ~/your-notes ingest.
What you get
As a solo user / knowledge worker
- A vault of human-readable markdown files — nothing proprietary, no lock-in. Your notes outlive any tool.
- Hybrid retrieval that combines keyword search, semantic similarity, and graph traversal so you find the right note even when you don't remember the exact words.
- AI-assisted tagging, link suggestions, and gap detection that grow your knowledge base instead of letting it rot.
- A CLI and a web UI for browsing, editing, and visualizing the graph.
As an AI agent / IDE user
- A first-class Model Context Protocol (MCP) server with 30+ tools, working out of the box with Claude Desktop, Claude Code, Cursor, Cline, Windsurf, Continue, Zed, VS Code, Goose, Gemini CLI, OpenAI Codex CLI, and others.
- Autonomous "auto-save" hooks that capture decisions and context from your AI conversations into the vault automatically.
- Per-conversation memory recall — your assistant can pull "what did we decide last week about X" without you copy-pasting context every time.
As an enterprise / SaaS operator
- Multi-tenant deployment with filesystem-level isolation per tenant, end-to-end isolation tests, and a warm-LRU kernel cache.
- OIDC + API-key authentication with JWKS support (Auth0, Clerk, WorkOS, Keycloak, Azure AD, Okta), restrictive CORS, request-size caps, and rate limiting.
- GDPR-compliant scheduled deletion: tombstone-with-grace-period flow, automatic final backups, daily reaper, and an audit log of every deletion.
- Observability built in: OpenTelemetry traces + Prometheus
/metrics, structured JSON logging with request IDs, and a separate/healthz//readyzfor orchestration. - Operations runbooks shipped with the code: install, SSO setup, RBAC, backup-restore, and GDPR procedures.
How consumers benefit
✨ Capabilities at a glance
Core memory engine
- Graph-based memory — bidirectional
[[wikilinks]]build a navigable knowledge graph automatically. - Hybrid retrieval — keyword + semantic embeddings + graph traversal, combined and re-ranked.
- Memory types inspired by cognitive science: episodic, semantic, procedural, fact.
- Salience scoring (0–1) that decays over time and boosts on access.
- Smart indexing — mtime-cached, only re-parses changed files.
- Context compression — token-budget-aware windowing for LLM prompts.
- Markdown-native vault — every memory is a
.mdfile with YAML frontmatter; no proprietary format.
AI features
- Smart Auto-Organization Engine — extract topics, people, action items, decisions, questions, sentiment, risks, ideas, and timeline events from memories.
- AutoTagger — suggest tags via semantic analysis, structure detection, and pattern learning.
- LinkSuggester — propose
[[wikilinks]]to related notes; bidirectional opportunities included. - GapDetector — surface missing topics, weak coverage, isolated notes, and unmade links.
- Knowledge analysis — vault stats, topic clustering, learning paths, connection analysis.
Interfaces
- Python API —
MemoryKernelwith sync, async, and batch variants. - CLI — 24+ commands for ingest, search, batch ops, import, export, backup, and AI features.
- MCP server — 30+ tools, stdio transport, drop-in for any MCP-compatible client.
- Web UI — React + D3 graph visualization, search, and editing (FastAPI backend + Vite frontend).
- HTTP API — versioned
/api/v1/, OpenAPI snapshot in CI, ready for service-to-service integration.
Enterprise & SaaS readiness
- Multi-tenancy with filesystem-isolated tenants, an LRU registry of warm kernels, per-tenant audit logs, and end-to-end isolation tests gating release.
- Authentication via OIDC (JWKS) or hashed API keys; per-route auth scope; identity bound into the audit log.
- Web hardening — restrictive CORS, slowapi rate limiting, request-size caps, structured JSON logging with request IDs, info-leak-free 500 handler.
- Storage hardening — path-traversal-safe vault writes, vault size soft/hard caps, schema-versioned cache files.
- Scheduled deletion for GDPR Art. 17: tombstone with configurable grace period, automatic final backup, daily reaper script, cancel-before-grace endpoint.
- Observability — OpenTelemetry FastAPI/asyncio auto-instrumentation, Prometheus
/metrics, OTLP export. - Reliability — concurrency audit, stress tests for concurrent writes, versioned backup format with integrity checks.
- Distribution — pinned-and-locked dependencies, Docker compose for self-host, security workflow (
bandit+pip-audit).
See docs/INSTALL_ENTERPRISE.md, docs/SSO_SETUP.md, docs/GDPR_RUNBOOK.md, docs/BACKUP_RESTORE_RUNBOOK.md, docs/OBSERVABILITY_GUIDE.md, and docs/RBAC_GUIDE.md for the operator-facing details.
🚀 Quick Start
Hosting it yourself? docs/HOSTING_GUIDE.md covers four genuinely-free paths — Oracle Free Tier, Cloudflare Tunnel + your hardware (recommended for most), GCP always-free stitch, and GitHub-repo-as-vault. Workspace identity via OIDC and Drive-as-portability-backup are documented in docs/GOOGLE_WORKSPACE_SETUP.md.
Installation
Install with optional dependencies:
Python Usage
🔌 MCP Server (Model Context Protocol)
MemoGraph includes a full-featured MCP server for seamless integration with AI assistants like Cline and Claude Desktop.
📖 New to MemoGraph MCP? See the MCP User Guide for practical usage instructions and examples!
🚨 Having connection issues? See Setup & Troubleshooting Guide - Common fixes for "cannot connect" errors!
19 Available Tools
Supported Clients
MemoGraph's MCP server is a stdio server — it runs alongside any MCP-compatible agentic CLI or editor. The full setup cookbook (config-file paths, format quirks, verification steps) lives in docs/MCP_CLIENTS.md:
Launching the MCP server
After pip install memograph (or uv tool install memograph), three launch commands are all equivalent:
memograph-mcp and memograph are both registered as console scripts: the first starts the MCP server, the second is the CLI. They do not collide.
Read-only mode
For shared deployments or untrusted clients, set MEMOGRAPH_READONLY=true. The server refuses every vault-writing tool — create_memory, import_document, update_memory, delete_memory, relate_memories, bulk_create, batch_update, batch_delete, import_backup_tool, and the auto-save hooks — and returns a structured {"success": false, "readonly": true, "error": "..."} payload instead. Read tools (search_vault, query_with_context, list_memories, get_memory, analytics, graph traversal) stay fully functional.
Quick Setup for Claude Desktop
Add to your claude_desktop_config.json:
If the memograph-mcp binary isn't on the client's PATH (common when the client launches without your shell environment), use the explicit module form instead:
Quick Setup for Cline
Add to your ~/.cline/mcp_settings.json:
For Claude Code, Cursor, Windsurf, Continue, Zed, VS Code, Goose, Gemini CLI, Codex CLI, LM Studio, Cherry Studio, and Bob Shell, see docs/MCP_CLIENTS.md.
Install from MCP Registry
NEW: MemoGraph is now available in the official MCP Registry! 🎉
Registry URL: https://github.com/modelcontextprotocol/servers/tree/main/src/memograph
Then drop the snippet for your client into its config file (see the table above or docs/MCP_CLIENTS.md).
Benefits of MCP Registry Listing:
- ✅ Official registry backed by Anthropic, GitHub, and Microsoft
- ✅ Discoverable by all MCP-compatible clients
- ✅ Verified server card and metadata
- ✅ Direct link from PyPI package
- ✅ Trusted by the MCP community
Note: The registry uses the PyPI package version. When you pip install memograph, you automatically get the latest registry-listed version.
See MCP_REGISTRY_GUIDE.md for complete submission and configuration guide.
Usage Examples
Once configured, use natural language with your AI assistant:
See CONFIG_REFERENCE.md for complete MCP configuration guide.
Using Auto-Save Hooks
MemoGraph provides autonomous hooks to save conversations automatically:
- ⚠️ Important: Hooks are passive tools - see Autonomous Hooks Guide for setup
- 📝 Quick fix: Add custom instructions to Claude Desktop (instructions in guide)
- 🔧 Configure with
MEMOGRAPH_AUTONOMOUS_MODE=true
Read the full Autonomous Hooks User Guide →
🎯 CLI Usage
MemoGraph comes with a powerful CLI for managing your vault and chatting with it.
Ingest
Index your markdown files into the graph database:
Force re-indexing all files:
Remember
Quickly add a memory from the command line:
Context Window
Generate context for a query:
Ask (Interactive Chat)
Start an interactive chat session with your vault context:
Or ask a single question:
Diagnostics
Check your environment and connection to LLM providers:
Batch Operations
Efficiently manage multiple memories at once:
Data Management
Export, backup, and restore your vault:
Configuration & Statistics
Manage settings and view vault analytics:
MCP Setup
Interactive wizard to configure MCP server for Claude Desktop or Cline:
📖 Complete CLI Documentation: See CLI Usage Guide for detailed documentation with 200+ examples covering all 24 commands.
🤖 AI Features
MemoGraph includes powerful AI-powered features to enhance your knowledge management workflow. See AI Features Guide for complete documentation.
🏷️ AutoTagger - Intelligent Tag Suggestions
Automatically suggest relevant tags using semantic analysis, content structure, and existing patterns:
Features: Frequency-based extraction • Semantic similarity • Structure detection • Pattern learning • Confidence scoring
🔗 LinkSuggester - Smart Wikilink Recommendations
Intelligently recommend wikilinks to related notes using semantic similarity and graph analysis:
Features: Semantic search • Keyword matching • Graph-based suggestions • Bidirectional detection • Target previews
🔍 GapDetector - Knowledge Base Analysis
Identify missing topics, weak coverage, and isolated notes in your vault:
Gap Types: Missing Topics • Weak Coverage • Isolated Notes • Missing Links
📊 Knowledge Analysis - Comprehensive Insights
Get comprehensive analysis of your entire knowledge base:
Analysis Includes: Vault statistics • Topic clustering • Learning paths • Gap detection • Connection analysis
Python API for AI Features
📖 Complete Documentation:
- AI Features Guide - Comprehensive guide with examples
- Web UI Guide - Using AI features in the browser
- MCP AI Tools Guide - AI features for Claude & Cline
💡 Use Cases: Auto-organize notes • Discover connections • Identify gaps • Maintain consistency • Build learning paths
📖 Core Concepts
Memory Types
MemoGraph supports different types of memories inspired by cognitive science:
- Episodic: Personal experiences and events (e.g., meeting notes)
- Semantic: Facts and general knowledge (e.g., documentation)
- Procedural: How-to knowledge and processes (e.g., tutorials)
- Fact: Discrete factual information (e.g., configuration values)
Graph Traversal
The library uses BFS (Breadth-First Search) to traverse your knowledge graph:
Salience Scoring
Each memory has a salience score (0.0-1.0) that represents its importance:
🏗️ Project Structure
🤝 Contributing
We welcome contributions! Please see our Contributing Guide for details.
Development Setup
-
Clone the repository:
-
Install in development mode:
-
Install pre-commit hooks:
-
Run tests:
Code Quality
We maintain high code quality standards:
- Linting: Ruff for fast Python linting
- Formatting: Ruff formatter for consistent code style
- Type Checking: MyPy for static type analysis
- Testing: Pytest with comprehensive test coverage
- Pre-commit Hooks: Automated checks before each commit
📚 Documentation
Getting Started
- Hosting Guide - 💸 Free hosting options (Oracle Free Tier, Cloudflare Tunnel, GCP, GitHub-vault) with hardening checklist
- Google Workspace Setup - 🔐 OIDC identity + Drive portability backup
- MCP Clients Guide - 🔌 Setup snippets for 15+ agentic CLIs/editors (Claude Code, Cursor, Windsurf, Continue, Zed, VS Code, Goose, Gemini CLI, Codex CLI, LM Studio, …)
- MCP User Guide - ⭐ Start here! Complete guide for using MemoGraph MCP
- Setup & Troubleshooting - 🚨 Can't connect? Step-by-step fixes for connection issues
- MCP Testing Guide - Testing your MCP server after setup
For Developers & Contributors
- MCP Registry Guide - Publishing to official MCP Registry
- Versioning Strategy - Semantic versioning and release planning
- AGENTS.md - Guide for AI agents working with this codebase
- Contributing Guide - How to contribute to the project
- Code of Conduct - Community guidelines
- Security Policy - Security reporting and best practices
- Changelog - Version history and changes
🔒 Security
See our Security Policy for reporting vulnerabilities.
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🌟 Acknowledgments
Inspired by the need for better memory management in LLM applications. Built with:
- Graph-based knowledge representation
- Hybrid retrieval strategies
- Cognitive science principles
📬 Contact & Support
- Issues: GitHub Issues
- Discussions: GitHub Discussions
📣 Community & Feedback
We value community feedback and contributions! Here's how to get involved:
Report Issues
Found a bug or have a feature request? Open an issue on GitHub.
Discussions
Join the conversation in GitHub Discussions:
- Ask questions
- Share use cases
- Suggest improvements
- Show what you've built
Contributing
We welcome contributions! See our Contributing Guide for details on:
- Code contributions
- Documentation improvements
- Bug reports and feature requests
- Community support
Stay Updated
- ⭐ Star the repository on GitHub
- 👁️ Watch for updates and releases
- 📦 Follow the project on PyPI
- 🔗 Check out the MCP Registry listing
🚦 Status
Current version: 0.3.0
Single-tenant deployments are stable and recommended for production use. Multi-tenant deployments are feature-complete with end-to-end isolation tests gating the release; the public API will stabilise at v1.0.
- ✅ Core functionality stable and tested (172+ tests across security, contract, and tenancy suites)
- ✅ Whole-package type-checked with MyPy
- ✅ Ruff lint + format + pre-commit hooks
- ✅ OpenAPI v1 contract snapshot in CI
- ✅ Multi-tenant isolation invariants verified by an e2e test suite
- ⚠️ Public API may change in minor versions until v1.0.0
What landed recently
- Phase 3.7 — GDPR-compliant scheduled tenant deletion: tombstone-with-grace-period, daily reaper, automatic final backups.
- Phase 3.5 —
TenantRegistrywired into the request path; non-admin routes resolve their kernel per-tenant. - Phase 3 scaffold — multi-tenancy ADR,
TenantStorage,TenantRegistry, admin routes for tenant lifecycle. - Phase 2 — OpenTelemetry + Prometheus, structured JSON logging, concurrency audit, stress tests.
- Phase 1 — OIDC + API-key auth, slowapi rate limiting, restrictive CORS, request-size caps, vault size caps, schema-versioned caches, OpenAPI v1 contract, security test suite.
- Phase 0 — path-traversal-safe vault writes, info-leak-free error handlers, pinned dependencies, Docker compose, security CI workflow.
- 📦 Published to the official MCP Registry (io.github.indhar01/memograph)
Made with ❤️ for better LLM memory management
Source: README.md at commit 453f407
Tools
0Version history
1- v0.4.0LatestSep 16, 2026
Score
50% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts