Memory Type Comparison
Rekall provides seven distinct memory types, each optimized for a specific pattern of storage, retrieval, and lifecycle management. Use this reference to choose the right type for your use case.
Comparison Table
| Type | Storage Backend | TTL | Search Support | Context Support | Use Case | API Prefix |
|---|---|---|---|---|---|---|
| Episodic | PostgreSQL + Qdrant | Configurable (default: none) | Semantic + temporal + filters | Agent, User, Hive | Conversation history, event logs, interaction records | /v1/memories/episodic |
| Semantic | Neo4j + Graphiti | None (persistent) | Graph traversal + semantic | Agent, User, Hive | Knowledge graphs, entity relationships, domain facts | /v1/memories/semantic |
| Procedural | PostgreSQL | None (persistent) | Pattern matching + semantic | Agent, User, Hive | Learned workflows, repeatable processes, step-by-step procedures | /v1/memories/procedural |
| Long-Term | PostgreSQL + Qdrant | Decay curve (strengthens on retrieval) | Semantic + relevance scoring | Agent, User | Consolidated knowledge, important facts, core preferences | /v1/memories/long-term |
| Short-Term | Redis | Session-scoped (default: 3h) | Key lookup + recency | Agent, Session | Working context, current conversation state, temporary data | /v1/memories/short-term |
| Execution | PostgreSQL + Redis | Task-scoped (configurable) | Task ID + status filters | Agent | Agent task state, checkpoints, pause/resume, execution logs | /v1/memories/execution |
| Preferences | PostgreSQL | None (persistent) | Category + confidence scoring | User | User preferences, inferred settings, personalization data | /v1/memories/preferences |
Storage Backends
PostgreSQL + Qdrant
PostgreSQL for structured memory data, Qdrant for vector embeddings. Supports semantic search via cosine similarity with HNSW indexing.
Neo4j + Graphiti
Native graph database for knowledge graphs via Graphiti. Supports entity-relationship modeling, graph traversal, and temporal knowledge management.
PostgreSQL
Relational storage for structured data without vector requirements. Used for workflows, preferences, and execution metadata.
Redis
In-memory store for session-scoped data requiring sub-millisecond access. Data is ephemeral by design.
PostgreSQL + Redis
Hybrid storage combining persistent checkpoints with real-time state. Execution metadata in PostgreSQL, active state in Redis.
Decision Flowchart
Use this flowchart to determine which memory type best fits your requirements.
Is the data session-scoped or temporary?
→ Yes: Is it agent task state with checkpoints?
→ Yes: Use Execution memory
→ No: Use Short-Term memory
→ No: Is it about user preferences or personalization?
→ Yes: Use Preferences memory
→ No: Is it a workflow or repeatable process?
→ Yes: Use Procedural memory
→ No: Is it entity/relationship data (knowledge graph)?
→ Yes: Use Semantic memory
→ No: Is it event-based (what happened, when)?
→ Yes: Use Episodic memory
→ No: Use Long-Term memory (consolidated knowledge)
Common Combinations
Memory types work together
Most production agents use 3-4 memory types in combination. Here are the most common patterns.
Conversational Agent
Short-Term for current session context + Episodic for conversation history + Preferences for user personalization.
Research Agent
Semantic for knowledge graphs + Long-Term for consolidated findings + Procedural for learned research workflows.
Task Automation Agent
Execution for task state and checkpoints + Procedural for learned workflows + Episodic for task history and audit trail.
