A JSONL store holds sessions only. Intercom continues using its own store (local files by default, or top-level
storage when configured).When to choose JSONL
Choose JSONL when you want sessions as ordinary plain-text files on a single machine:- Inspect, grep, or diff sessions with standard text tools.
- Copy or back up the folder like any regular directory.
- Delete individual sessions by deleting their files.
Select a JSONL store
Configuresessions.storage in ~/.atomic/agent/settings.json or a trusted project’s .atomic/settings.json:
Use an absolute path to avoid path-resolution surprises. Atomic creates the directory automatically if it does not exist. From the SDK, pass
sessionStore: { kind: "jsonl", dir } (see SDK session storage).
Validation rules:
{ "dir": "..." }is valid only insessions.storageandATOMIC_SESSIONS_STORAGE. Using it in top-levelstorage,--storage,--storage-file, orATOMIC_STORAGEfails withStorageConfigError.--session-dircannot be combined with--session-storeor--no-session.- A non-empty
ATOMIC_CODING_AGENT_SESSION_DIRcannot be combined withATOMIC_SESSIONS_STORAGE,--storage, or--storage-file(StorageConfigErrorwith reasonconflicting-overrides).
atomic storage status in your project directory to inspect the active store.
Where the files go
Session files sit directly inside the directory you selected:: and . replaced with -), _, and the hex SHA-256 hash of the session ID. Sessions from all projects share the same directory; line 1 records cwd, which /resume uses to filter sessions for the current project.
Alongside .jsonl files, Atomic maintains these sidecars and folders:
To delete a session, select it in
/resume and press Ctrl+D (moves to trash when a trash command is installed), or delete its .jsonl and .jsonl.idx files directly.
Several Atomic processes
Multiple Atomic processes on one machine can safely share the same JSONL directory at the same time:- Parallel across sessions, serialized per session. Writers coordinate through operating-system advisory locks striped across 32 lock files (while also maintaining
.session.lockfor compatibility with older Atomic releases). Writes to different session files proceed concurrently, while writes to the same session file wait in order. If a writer process crashes or is killed, the OS releases its lock immediately so the next writer proceeds without waiting out a 10-second stale timeout. - Crash-safe grouped saves. Saves queued behind an active write are batched together under one lock, and every save waits until its bytes are synced to disk before being acknowledged. New, forked, or replaced session files are synced before being renamed into place.
- File handles during writes. On Unix/macOS, Atomic keeps an active session file open between rapid saves and closes it once writes pause. On Windows, Atomic closes each file immediately after writing so other operations can delete or replace it.
What JSONL doesn’t do
Compared with local SQLite or PostgreSQL, a JSONL directory store:- Cannot be shared across machines. Use PostgreSQL for multi-machine access.
- Writes full copies on fork. Unlike SQLite and PostgreSQL shared-history forks, JSONL forks duplicate the full parent file on disk.
- Does not record worktree snapshots. Worktree snapshots require a SQL database store.
- Cannot resume subagents on another machine. Subagents launched from a JSONL store stay tied to the local machine (see Resume on any machine).
Move to SQLite or PostgreSQL
1
Export your JSONL sessions
Run
atomic storage export while the JSONL store is still selected. If you normally select it with --session-dir, pass ATOMIC_SESSIONS_STORAGE for this command instead (atomic storage export does not accept --session-dir):2
Stop selecting the JSONL store
Remove
sessions.storage from your settings, and unset ATOMIC_SESSIONS_STORAGE and ATOMIC_CODING_AGENT_SESSION_DIR.3
Import into SQLite or PostgreSQL
4
Verify and clean up
Confirm your sessions appear in
/resume and atomic storage status shows the new store. Import leaves the original JSONL files untouched—delete the directory once you verify everything migrated. See Exporting and importing sessions for details.