FalkorDB/GraphRAG-SDK
Build fast and accurate GenAI apps with GraphRAG SDK at scale 🌟
What it solves
GraphRAG-SDK addresses the limitations of standard Vector RAG, which often fails in production by only matching similar text chunks. It provides a framework to build GraphRAG systems that can traverse complex relationships between entities across multiple documents, leading to higher accuracy for complex queries and providing clear citations for every answer.
How it works
The SDK uses FalkorDB as its underlying graph database. The process follows a specific pipeline:
- Ingestion: It extracts entities and relations from raw text or PDFs using an LLM, resolves and deduplicates those entities, and then embeds and indexes them.
- Retrieval: It combines vector search, full-text search, and graph traversal (relationship expansion) to find relevant information. It also supports experimental text-to-Cypher queries.
- Generation: The retrieved context is passed to an LLM to generate a final answer, with a provenance trail (MENTIONS edges) that links the answer back to the original source chunks.
Who it’s for
It is designed for developers building production-grade AI applications that require high accuracy across large, multi-document datasets where understanding the relationships between entities is critical.
Highlights
- High Accuracy: Outperforms several other GraphRAG systems on the GraphRAG-Bench (Novel and Medical datasets).
- Incremental Updates: Supports updating, deleting, or adding individual documents without rebuilding the entire graph, featuring crash-safe idempotent updates.
- Multi-tenant Support: Provides per-tenant isolation via graph names.
- Flexible Schema: Allows users to define custom entity types and relation types to guide the extraction process.
- Modular Design: Supports pluggable LLM and embedder providers via a clean interface (e.g., LiteLLM).