Skip to main content

JSON

Simple JSON file-based storage for development.

Quick Start

File Location

By default, JSON files are stored in:
  • ~/.praisonai/memory/ for memory data
  • ~/.praisonai/sessions/ for session data

When to Use

Good for:
  • Local development
  • Testing
  • Quick prototyping
Not recommended for:
  • Production deployments
  • Multi-user applications
  • Large datasets

Storage Backend (Advanced)

For training data, sessions, and general persistence, use the FileBackend:
TrainingStorage is a context manager. FileBackend holds no open connection, so .close() is a safe no-op here — but using with keeps the pattern identical to the SQLite and Redis backends, where closing releases a file or network handle (essential on Windows and for long-running processes).

CLI Usage

See Storage Backends for more details.