
What is Graphiti?
Graphiti is a Python framework for building and querying temporally-aware knowledge graphs, specifically designed for AI agents operating in dynamic environments. Unlike traditional retrieval-augmented generation (RAG) methods, Graphiti continuously integrates user interactions, structured and unstructured enterprise data, and external information into a coherent, queryable graph. The framework supports incremental data updates, efficient retrieval, and precise historical queries without requiring complete graph recomputation, making it ideal for developing interactive, context-aware AI applications.Real-Time Updates
Immediate integration of new data episodes without batch recomputation
Bi-Temporal Data Model
Explicit tracking of event occurrence and ingestion times for accurate point-in-time queries
Hybrid Retrieval
Combines semantic embeddings, keyword (BM25), and graph traversal for low-latency queries
Custom Entity Definitions
Flexible ontology creation with developer-defined entities through Pydantic models
Key Use Cases
Graphiti enables powerful capabilities for AI applications:- Agent Memory: Give AI agents persistent, queryable memory of past interactions and learned facts
- Dynamic Data Integration: Continuously maintain user interactions and business data
- State-Based Reasoning: Facilitate task automation and decision-making for agents
- Complex Data Querying: Query evolving data with semantic, keyword, and graph-based search methods
How Knowledge Graphs Work
A knowledge graph is a network of interconnected facts. Each fact is a “triplet” represented by:- Two entities (nodes) - for example: “Kendra”, “Adidas shoes”
- A relationship (edge) connecting them - for example: “loves”

Why Choose Graphiti?
Traditional RAG approaches often rely on batch processing and static data summarization, making them inefficient for frequently changing data. Graphiti addresses these challenges:Real-Time Incremental Updates
Real-Time Incremental Updates
Add new data episodes immediately without batch recomputation. Graphiti processes each episode incrementally, extracting entities and relationships in real-time.
Bi-Temporal Data Model
Bi-Temporal Data Model
Track both when events occurred and when they were ingested into the system. This enables accurate point-in-time queries and contradiction handling through temporal edge invalidation.
Efficient Hybrid Retrieval
Efficient Hybrid Retrieval
Achieve low-latency queries without relying on LLM summarization. Graphiti combines semantic embeddings, BM25 keyword search, and graph traversal for typically sub-second latency.
Custom Entity Definitions
Custom Entity Definitions
Define your own entity types and relationships using straightforward Pydantic models. Create flexible ontologies tailored to your specific domain.
Scalability
Scalability
Efficiently manage large datasets with parallel processing, suitable for enterprise environments. Works with multiple graph database backends including Neo4j, FalkorDB, Kuzu, and Amazon Neptune.
Graphiti vs. GraphRAG
Graphiti is optimized for dynamic, continuously updating data rather than static document summarization:| Aspect | GraphRAG | Graphiti |
|---|---|---|
| Primary Use | Static document summarization | Dynamic data management |
| Data Handling | Batch-oriented processing | Continuous, incremental updates |
| Knowledge Structure | Entity clusters & community summaries | Episodic data, semantic entities, communities |
| Retrieval Method | Sequential LLM summarization | Hybrid semantic, keyword, and graph-based search |
| Adaptability | Low | High |
| Temporal Handling | Basic timestamp tracking | Explicit bi-temporal tracking |
| Contradiction Handling | LLM-driven summarization judgments | Temporal edge invalidation |
| Query Latency | Seconds to tens of seconds | Typically sub-second latency |
| Custom Entity Types | No | Yes, customizable |
| Scalability | Moderate | High, optimized for large datasets |
Architecture
Graphiti uses a pluggable driver architecture, making the core framework backend-agnostic:- Graph Databases: Neo4j, FalkorDB, Kuzu, Amazon Neptune
- LLM Providers: OpenAI, Azure OpenAI, Anthropic, Google Gemini, Groq, Ollama
- Embeddings: OpenAI, Azure OpenAI, Voyage AI, Google Gemini, local models
- Search: Hybrid semantic + keyword (BM25) + graph traversal
Graphiti and Zep
Graphiti powers the core of Zep’s context engineering platform for AI Agents. Using Graphiti, Zep demonstrates State of the Art in Agent Memory. Read the paper: Zep: A Temporal Knowledge Graph Architecture for Agent Memory.Zep vs Graphiti
| Aspect | Zep | Graphiti |
|---|---|---|
| What they are | Fully managed platform for context engineering and AI memory | Open-source graph framework |
| User & conversation management | Built-in users, threads, and message storage | Build your own |
| Retrieval & performance | Pre-configured, production-ready retrieval with sub-200ms performance at scale | Custom implementation required; performance depends on your setup |
| Developer tools | Dashboard with graph visualization, debug logs, API logs; SDKs for Python, TypeScript, and Go | Build your own tools |
| Enterprise features | SLAs, support, security guarantees | Self-managed |
| Deployment | Fully managed or in your cloud | Self-hosted only |
Next Steps
Quickstart
Get up and running with Graphiti in minutes
Installation
Install Graphiti with your preferred package manager and backend
