lightrag-mcp
lightrag-mcp
MCP-сервер, который подключает LightRAG к любому MCP-клиенту — Cursor, Claude Desktop и другим. Даёт агенту доступ к постоянной базе знаний: заметкам, решениям, документации, ранбукам.
Два инструмента, потому что у извлечения знаний два разных сценария:
Инструмент | Что делает | Когда нужен |
| Возвращает готовый ответ со ссылками на источники | Обычный вопрос к базе знаний |
| Возвращает только контекст и источники, без генерации ответа | Когда ответ нужно собрать самому: сверить с кодом, совместить с текущим диалогом |
Оба инструмента помечены как readOnlyHint, поэтому клиент не будет
воспринимать их как изменяющие состояние.
Установка
npm installТребуется Node.js 18 или новее — используется встроенный fetch.
Related MCP server: expert-mcp-server
Настройка
Создайте .env рядом с package.json:
LIGHTRAG_URL=http://localhost:9621
LIGHTRAG_API_KEY=ваш-ключLIGHTRAG_URL необязателен и по умолчанию равен http://localhost:9621.
LIGHTRAG_API_KEY обязателен: без него сервер падает на старте с внятной
ошибкой, а не в момент первого запроса.
Путь к файлу окружения можно переопределить переменной
LIGHTRAG_MCP_ENV_FILE — удобно, когда клиент запускает сервер из другого
рабочего каталога.
Подключение к Cursor
В ~/.cursor/mcp.json:
{
"mcpServers": {
"lightrag": {
"command": "node",
"args": ["/абсолютный/путь/lightrag-mcp/src/server.js"],
"env": {
"LIGHTRAG_MCP_ENV_FILE": "/абсолютный/путь/lightrag-mcp/.env"
}
}
}
}Режимы поиска
Параметр mode принимает mix (по умолчанию), hybrid, local, global и
naive. Неизвестный режим отклоняется до сетевого запроса. Запросы всегда
уходят с включёнными ссылками на источники и реранкингом.
Тесты
npm testТесты используют встроенный node --test, без внешних зависимостей. HTTP
подменяется через параметр fetchImpl, поэтому проверяются и успешные ответы,
и ошибки: отсутствующий ключ, пустой вопрос, неизвестный режим, неуспешный
статус ответа.
Лицензия
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceAn MCP server that enables AI agents to query specialized, domain-specific knowledge bases built using the LightRAG framework for enhanced retrieval-augmented generation. It allows for managing and searching knowledge graphs and vector embeddings to provide accurate, context-aware information during an AI assistant's reasoning process.59MIT
- AlicenseAqualityDmaintenanceEnables MCP-compatible agents to query beliefs, search documents, and explore reasoning chains from expert-service knowledge bases.10MIT
- AlicenseNot gradedqualityBmaintenanceEnables document-based Q&A with multi-modal RAG, hybrid retrieval, knowledge graph reasoning, and multi-agent orchestration via MCP tools.4MIT
- FlicenseNot gradedqualityCmaintenanceEnables querying company knowledge base using RAG, providing accurate answers from internal documents via MCP.
Related MCP Connectors
Your memory, everywhere AI goes. Build knowledge once, access it via MCP anywhere.
Shared, peer-validated knowledge archive for AI agents — search, contribute, and validate via MCP
Agentic search over your Dewey document collections from any MCP-compatible client.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/TimaxLacs/lightrag-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server