Skip to main content

SQLite

SQLite is the simplest option for local development and testing.

Installation

Quick Start

File Path Options

Environment Variables

CLI

When to Use SQLite

Good for:
  • Local development
  • Testing
  • Single-user applications
  • Prototyping
Not recommended for:
  • Production multi-user apps
  • High concurrency
  • Distributed systems

Storage Backend (Advanced)

For training data, sessions, and general persistence, use the SQLiteBackend:
TrainingStorage is a context manager. Using with (or calling .close() explicitly) releases the underlying SQLite connection so the database file can be deleted or reopened immediately — essential on Windows, and best practice everywhere for long-running processes. On backends without an open resource (e.g. FileBackend) .close() is a safe no-op.

CLI Usage

See Storage Backends for more details.

Troubleshooting

File permissions:
Database locked:
  • SQLite only allows one writer at a time
  • Use PostgreSQL for concurrent access