Memgraph AI Toolkit
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
Build powerful AI applications with graph-powered RAG using Memgraph. This toolkit provides everything you need to integrate knowledge graphs into your GenAI workflows.
🚀 Quick Setup
Start Memgraph
Install Packages
---
📚 Usage Examples
Context Graph - Capture Your Agent Sessions
Turn your coding agents' sessions (Claude Code, Codex, Copilot CLI, Cursor, OpenCode, Antigravity CLI, Grok Build) into a queryable knowledge graph. Every session records the tools it called, the skills it used, and the memories it wrote — all joined on a shared (:Session) node in Memgraph.
One command finds or starts Memgraph, wires every agent it finds, sets your identity and checks the result (interactive on a terminal):
Query across every session — e.g. which skills a user has used:
👉 Context Graph guide — components, Codex setup, SDK usage, and reconciling sessions into an entity graph.
---
unstructured2graph - Build Knowledge Graphs from Documents
Transform PDFs, URLs, and documents into queryable knowledge graphs:
extraction_backend is pluggable — LightRAGBackend (LLM-based, shown above) or GLiNER2Backend (local, LLM-free) — see unstructured2graph § choosing an extraction backend.
👉 Full Documentation | Examples
---
langchain-memgraph - LangChain Integration
Natural Language Queries with MemgraphQAChain
Build Agents with MemgraphToolkit
👉 Full Documentation
---
mcp-memgraph - Model Context Protocol Server
Expose Memgraph to LLMs via MCP. Run with Docker:
**Available Tools:**
| Tool | Description |
| ------------------------ | ----------------------------------------------------- |
| run_query | Execute Cypher queries |
| search_schema | Search the graph schema by regex pattern |
| get_node_schema | Get full schema definition of a node by its labels |
| get_relationship_schema| Get full schema definition of a relationship |
| get_enum_schema | Get schema definition of an enum by its name |
👉 Full Documentation
---
sql2graph Agent - Automated Database Migration
Migrate from MySQL/PostgreSQL to Memgraph with AI assistance:
👉 Full Documentation
---
🛠️ Packages Overview
| Package | Description | Install |
| ------------------------------------------------------- | ---------------------------- | -------------------------------- |
| memgraph-toolbox | Core utilities for Memgraph | pip install memgraph-toolbox |
| langchain-memgraph | LangChain tools and chains | pip install langchain-memgraph |
| mcp-memgraph | MCP server for LLMs | pip install mcp-memgraph |
| unstructured2graph | Document to graph conversion | pip install unstructured2graph |
| lightrag-memgraph | LightRAG storage on Memgraph | pip install lightrag-memgraph |
| sql2graph | Database migration agent | See docs |
Context Graph — capture agent sessions
A family of components that persist your coding-agent sessions (Claude Code, Codex, Copilot CLI, Cursor, OpenCode, Antigravity CLI, Grok Build) into one Memgraph graph. See the Context Graph guide.
| Package | Description | Install |
| --------------------------------------------------------------- | ---------------------------------------------- | ----------------------------------- |