Skip to main content
Memory in Fibonacci allows workflows to store and retrieve data across executions, enabling stateful applications like chatbots, progressive data collection, and user preference tracking.

Memory Scopes

Fibonacci provides four memory scopes, each with different visibility and lifecycle:
ScopeVisibilityUse Case
workflowSingle workflowExecution history, intermediate results
userSingle user across workflowsPreferences, conversation history
organizationAll users in organizationShared knowledge bases, company data
globalAll workflows and usersApplication-wide settings

Basic Usage

Storing Memory

Retrieving Memory

Deleting Memory

Memory in Nodes

Nodes can read from and write to memory using template variables and the memory parameter:

Reading Memory in Prompts

Writing Memory from Nodes

Building Stateful Applications

Conversational Chatbot

Build a chatbot that remembers conversation history:

User Preference Learning

Track and apply user preferences over time:

Progress Tracking

Track multi-step process progress:

Memory Patterns

Caching Expensive Operations

Rate Limiting

Session Management

Memory Configuration

Default Memory Backend

By default, Fibonacci uses an in-memory store. For production, configure a persistent backend:

Memory Encryption

Enable encryption for sensitive data:

Best Practices

Match memory scope to data sensitivity and sharing requirements:
  • workflow: Temporary execution data
  • user: Personal preferences, history
  • organization: Shared resources, team data
  • global: Application configuration
Always set TTL for caches, sessions, and temporary data to prevent unbounded growth:
Use consistent, hierarchical key naming:
Always provide defaults when reading memory:
Cap array-based memory (like chat history) to prevent unbounded growth:

Next Steps

Workflows Guide

Learn workflow lifecycle management

Conditional Logic

Add branching based on memory values