Session events and projections

DataMind Oda keeps a chat's lasting state inside the chat itself. Plan mode, the preset the chat runs under, its file policy and its link to a scheduled run are recorded as small events in the chat's own log, and Oda reads them back into current values, the projections, whenever it needs to show or continue the chat. This page is written for people who support chats or inspect session logs. It describes what each part records, and what a chat rebuilds when it is reopened. For the log itself, see Chat log format.

What a chat records, and what it reads back

Rebuilding a chat's state

Oda rebuilds these values from the chat's own events whenever it reads the chat again:

A rebuild reads the events in order, so the value that last took effect wins.

Plan mode

The preset a chat runs under

The file policy a chat runs under

Scheduled-run markers

Questions, answered

What is a session event, and what is a projection?

An event is one note a chat writes into its own log, like the record of a plan-mode switch or a preset choice. A projection is a small current value Oda builds from those events, such as whether plan mode is on, which preset the chat runs or whether the chat belongs to a scheduled run; Oda shows the chat's state from the projection instead of replaying every event each time.

Where do a chat's plan mode, preset and file policy live?

In the chat itself. Each of them is recorded as events inside the chat's own log on your computer, and each chat keeps its own values. For the log files themselves, see Chat logs on disk.

How does Oda rebuild these values when a chat is reopened?

From the chat's own events, read in order so the value that last took effect wins. A reopened chat continues with the same plan mode, the same preset and the same file policy; forked and helper chats are rebuilt from the events they carry the same way.

What wins when the same setting was changed more than once?

The newest value. These are whole-value records: a new record replaces the previous one instead of adding to it, so the value that last took effect is the one in force.

What does it mean that a plan-mode change is still pending?

You asked for a switch, and it has not taken effect yet. With Oda idle, the switch lands at once; while a step is running, the step finishes as it is and the switch applies from Oda's next step. Until it lands, the chat's state reads as two parts: the mode in effect and the pending change.

How does Oda know a chat is a scheduled run?

The run's chat records a small marker naming the task and the run. The app reads it to show the chat under Scheduled, list it in the task's run history and open it from a notification. See Scheduled runs and history.

Is a chat forked from a run still shown as a run?

No. The marker counts only in the chat that recorded it. A fork keeps the run's events as inherited history, but the inherited marker is skipped, so the fork is an ordinary chat.

Do these records appear in the conversation?

No. They are notes the chat keeps for itself, not messages. Where a feature adds a notice of its own, such as plan mode's switch notice, that notice is a separate message; the feature's page covers it.

Why does Oda not simply use the preset noted when the chat was started?

Because the choice can change while the chat is still new, so the note from the start may not match what the chat actually ran under. Oda rebuilds the preset from the chat's own selection records instead, and the chat runs under the rebuilt choice.