Sessions & Memory
How CLIO manages conversation context and persistent memory
Session Management
CLIO automatically saves every conversation in a session file. Sessions persist across terminal restarts and can be resumed at any time.
Session Commands
# Start a new session
clio --new
# Resume your last session
clio --resume
# List all sessions
: /session list
# Switch to a specific session
: /session switch sess_20260208_173000
# Delete a session
: /session delete sess_20260208_173000
Session Storage
Sessions are stored in ~/.clio/sessions/ as JSON files. Each session contains:
- Full conversation history
- Tool call records
- Configuration snapshots
- Memory context
Memory System
CLIO includes two types of memory for context persistence:
Session Memory (Key-Value Store)
# Store information
: /memory store project_name my-cool-app
# Retrieve information
: /memory get project_name
# List all stored keys
: /memory list
# Search memory
: /memory search app
# Delete memory
: /memory delete project_name
Long-Term Memory (LTM)
LTM stores discoveries, solutions, and patterns across all sessions:
# Search previous session history
: /ltm recall "bug fix authentication"
# Add a discovery
: /ltm add-discovery "API endpoint changed to /v2/"
# Add a solution
: /ltm add-solution "TypeError: must use === not ==" "Change comparison operators"
# Add a pattern
: /ltm add-pattern "Always check null before accessing properties"
# View LTM statistics
: /ltm stats
# Prune old entries
: /ltm prune
Best Practices
- Use descriptive session names - Easier to find later
- Store project context - Architecture notes, file locations, conventions
- Record solutions - Add common fixes to LTM for future reference
- Prune periodically - Keep LTM relevant by removing old entries
Next Steps
- Workflows - Effective usage patterns
- Configuration - Customize session behavior
- Slash Commands - Full command reference