Skip to main content

Databases

Chaos Cypher supports multiple isolated databases, each containing its own sources, knowledge graph, chat history, search indexes, and configuration.

Multi-Database Architecture

Each database is a self-contained directory with:

databases/{name}/
└── app.db # All data: sources, chats, workflows, graph, search indices (SQLite default)
tip

The storage backend is pluggable via Core's hexagonal architecture: any class implementing the storage protocols in chaoscypher_core.ports can replace the default SQLite adapter.

Databases are completely isolated — switching databases loads an entirely different set of data.

Managing Databases

List Databases

View all available databases with their size and last modified date:

Go to SettingsDatabases to see all databases with their size, last modified date, and active status.

Settings page with database selector showing size

Current Database

Check which database is active:

The current database name is displayed in the header/navigation bar. You can also quickly switch databases from the sidebar dropdown without navigating to the Settings page.

Create a Database

  1. Go to SettingsDatabases
  2. Click Create Database
  3. Enter a name (alphanumeric, hyphens, and underscores allowed)

Database selector with create new database option

New databases are automatically initialized with the required directory structure and a fresh database.

Switch Database

Click on a database name in SettingsDatabases to switch to it. The UI refreshes to load the new context.

note

After switching databases, the web UI refreshes to load the new context. All subsequent API calls operate on the new database.

Delete a Database

Click the delete button next to a database in SettingsDatabases and confirm the deletion.

warning
  • You cannot delete the currently active database
  • You cannot delete the default database
  • Deletion is permanent and removes all data

What's Isolated

DataIsolated per database
Sources and document chunksYes
Knowledge graph (nodes, edges, templates)Yes
Chat conversations and messagesYes
Search indexes (fulltext + vector)Yes
Workflows and triggersYes
Tool registryYes
Quality scoresYes
TagsYes

Backup & Restore

Chaos Cypher includes built-in database backup and restore from the Settings > Backup tab:

  • Create backups — Snapshot the current database to a timestamped backup file
  • Scheduled backups — Configure automatic backups on a schedule
  • Restore — Restore a database from a previous backup
  • Download — Download backup files for offline storage
  • Manage — View, download, or delete existing backups

Backups capture the full database state including sources, knowledge graph, chat history, and search indexes.

Use Cases

  • Project separation — Keep different research projects in separate databases
  • Domain isolation — Separate databases for different knowledge domains
  • Testing — Create a test database without affecting production data
  • Snapshots — Create a new database, import a CCX package, and explore without modifying the original