# The device journal

Canonical URL: https://developers.iagenify.com/sdk/agent/sessions/journal/
Language: en

The full record of a session — tool arguments and results included — written on the device that ran it, and nowhere else.

Status: on the device · never on the account · never blocks a run

## Where it is {#where}

| Machine | Journal |
| --- | --- |
| A computer | `~/.iagenify/sessions/<id>.jsonl` — one line appended per batch of events |
| A phone, or a workspace whose files you supply | `.sessions/<id>/000001.json`, a small numbered file per write |

The second form exists because a supplied file system has no append: writing a new small file per batch is the shape that works on a browser's storage and on an object storage alike.

## What is in it {#contents}

The messages as the engine holds them — user, assistant, tool — which means the arguments and the **content** of every tool result. It is the only place that content exists after the process ends.

> **One thing never goes in: binary**
>
> An attached PDF, image or recording leaves only a count in the journal, not its bytes. A session journal therefore stays small even on a run that read a lot of media.

## It never stops a run {#never-fails}

Every read and write is guarded. A full disk, a missing folder, a storage that refuses — the journal is skipped and the run continues. A resume is then partial, which is a lesser harm than a failed answer.

## It is not a checkpoint {#checkpoints}

The journal records what was *said and done*; [checkpoints](/sdk/agent/checkpoints) record what the files *were*. Rewinding uses both, and the journal's own folder is excluded from a snapshot — otherwise going back to the first message would delete the record of how you got there.

## What it means for privacy {#privacy}

- What a file contained, what a database returned, what a page said: on the device.
- That a file was read, and which one: on the account.
- Deleting the session with `destroy()` removes both.

## Keeping it in hand {#size}

A journal grows with the conversation and is never trimmed on its own. [Compaction](/sdk/agent/context/compaction) writes a compacted state into it, so a long session resumes from the summary rather than from the beginning — and `destroy()` is what removes it.

- [Resuming](/sdk/agent/sessions/resuming): What comes back, from where.
- [How snapshots work](/sdk/agent/checkpoints/snapshots): The other thing kept on the device.
