---
sidebar:
  hidden: true
title: roboto.experimental.sessions.record
---
## Module Contents

### CompletionPolicy

```python
class roboto.experimental.sessions.record.CompletionPolicy(/, **data: Any)
```

`from roboto.experimental.sessions import CompletionPolicy`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L23-L40)

Bases: `pydantic.BaseModel`

Rule by which Roboto marks a session complete after a period with no new files.

Carried in `SessionRecord.completion_policy`. Set it when you create a session, with [`create()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.create), or change it with [`update()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.update). Building one raises `pydantic.ValidationError` when `inactivity_minutes` is less than 1 or more than 10,080 (`MAX_INACTIVITY_MINUTES`).

Roboto marks the session complete once `inactivity_minutes` have passed since a file was last added to it, or since the policy was changed, whichever is later. A session that no file has been added to yet is not completed this way. Adding a file to a session Roboto completed puts it back in progress, and Roboto marks it complete again after the same inactivity.

**Parameters**

- **data** (`Any`)

**Attributes**

- **CompletionPolicy.inactivity_minutes** (`int`) = `None`: Number of minutes without a new file after which Roboto marks the session complete, from 1 to 10,080.
- **CompletionPolicy.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

### MAX_INACTIVITY_MINUTES

```python
roboto.experimental.sessions.record.MAX_INACTIVITY_MINUTES = 10080
```

`from roboto.experimental.sessions.record import MAX_INACTIVITY_MINUTES`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L19-L19)

Maximum inactivity of a `CompletionPolicy`, in minutes: 10,080, one week.

### PendingIngestionFile

```python
class roboto.experimental.sessions.record.PendingIngestionFile(/, **data: Any)
```

`from roboto.experimental.sessions import PendingIngestionFile`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L209-L228)

Bases: `pydantic.BaseModel`

Ingestable file of a session that is not ingested yet, which the session waits for.

Carried in `SessionIngestionStatus.pending_files`.

**Parameters**

- **data** (`Any`)

**Attributes**

- **PendingIngestionFile.file_id** (`str`): ID of the file.

- **PendingIngestionFile.ingestion_status** (`roboto.domain.files.IngestionStatus`): How much of the file's current version is ingested.

  Either none of it ([`NotIngested`](/docs/reference/python-sdk/roboto/domain/files/record#roboto.domain.files.record.IngestionStatus.NotIngested)) or part of it (`PartlyIngested`).

- **PendingIngestionFile.last_run** (`roboto.experimental.ingestion_runs.IngestionRun | None`) = `None`: Latest run of an ingestion rule's trigger on the file's current version, or `None` if none has run.

- **PendingIngestionFile.relative_path** (`str`): Path of the file from the root of its dataset's, device's, or organization's files.

- **PendingIngestionFile.uploaded** (`datetime.datetime | None`) = `None`: Time the file's current version was uploaded.

### SessionDevice

```python
class roboto.experimental.sessions.record.SessionDevice(/, **data: Any)
```

`from roboto.experimental.sessions import SessionDevice`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L321-L330)

Bases: `pydantic.BaseModel`

Device attached to a session, with its device type.

Carried in [`devices`](/docs/reference/python-sdk/roboto/experimental/sessions/operations#roboto.experimental.sessions.operations.SessionDevicesResponse.devices).

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionDevice.device_id** (`str`): ID of the device.
- **SessionDevice.device_type_id** (`str | None`): ID of the device's type, or `None` if the device has none.

### SessionFileRecord

```python
class roboto.experimental.sessions.record.SessionFileRecord(/, **data: Any)
```

`from roboto import SessionFileRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L342-L397)

Bases: `pydantic.BaseModel`

Data record of one file a session holds, and the part of the file it holds.

No SDK method or Roboto route uses this model. [`list_files()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.list_files) yields `SessionFileView` instead, which describes the time window and data range the same way.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionFileRecord.created** (`datetime.datetime | None`) = `None`: Time the file was added to the session.

- **SessionFileRecord.created_by** (`str`): Principal that added the file to the session, as `<type>:<id>`, such as `user:<user_id>`.

- **SessionFileRecord.data_range** (`tuple[int, int] | None`) = `None`: Part of the file the session holds, or `None` when it holds the whole file.

  The part is `(start, end)` in the file's own units. `start` is the first position held; `end` is one past the last.

- **SessionFileRecord.fs_node_id** (`str`): ID of the file.

- **SessionFileRecord.max_wall_clock_timestamp_ns** (`int | None`) = `None`: End of the time window of the file the session holds, or `None` when it holds the file's whole time span.

  The end is inclusive, in nanoseconds since the Unix epoch.

- **SessionFileRecord.min_wall_clock_timestamp_ns** (`int | None`) = `None`: Start of the time window of the file the session holds, or `None` when it holds the file's whole time span.

  The start is inclusive, in nanoseconds since the Unix epoch.

- **SessionFileRecord.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionFileRecord.modified** (`datetime.datetime | None`) = `None`: Time the file's place in the session was last modified.

- **SessionFileRecord.modified_by** (`str`): Principal that last modified the file's place in the session.

  It is in the same `<type>:<id>` form as `created_by`.

- **SessionFileRecord.session_id** (`str`): ID of the session holding the file.

- **SessionFileRecord.unix_epoch_offset_ns** (`int | None`) = `None`: Wall-clock time of time 0 of the file's data the session holds, in nanoseconds since the Unix epoch.

  Roboto added it to the file's own timestamps to compute `min_wall_clock_timestamp_ns` and `max_wall_clock_timestamp_ns`; subtract it from a wall-clock time to read that time in the file's own timestamps. `None` when that data has no registered time span, or when its parts have different offsets.

### SessionFileView

```python
class roboto.experimental.sessions.record.SessionFileView(/, **data: Any)
```

`from roboto import SessionFileView`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L400-L489)

Bases: `pydantic.BaseModel`

Data record of a file a session holds, as the Roboto API returns it.

[`list_files()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.list_files) yields these, and [`add_file()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.add_file) and [`add_files()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.add_files) return them. `file_id`, `data_range`, the time window and `unix_epoch_offset_ns` describe the part of the file the session holds. Every other field describes the file itself: `created`, for example, is when the file was created, not when it joined the session.

Time window (`min_wall_clock_timestamp_ns` and `max_wall_clock_timestamp_ns`):

- Both are set or both are `None`. When both are `None`, the session holds the file's whole time span.
- When both are set, the window is the closed interval `[min_wall_clock_timestamp_ns, max_wall_clock_timestamp_ns]`, and a read scoped to the session returns only the file's data inside it.
- Values are nanoseconds since the Unix epoch. You state the window in the file's own timestamps, on [`SessionFile`](/docs/reference/python-sdk/roboto/experimental/sessions/operations#roboto.experimental.sessions.operations.SessionFile), and Roboto reports it here with the data's wall-clock anchor added (`unix_epoch_offset_ns`, when the data has one anchor).

Data range (`data_range`):

- `None` means the session holds the whole file.
- `(start, end)` names the part of a file several sessions share that belongs to this session. `start` is the first position held and `end` is one past the last, with `0 <= start < end`. Values are in the file's own units: stored-row positions counted from 0, or nanoseconds of media time for video.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionFileView.created** (`datetime.datetime | None`) = `None`: Time the file was created.

- **SessionFileView.data_range** (`tuple[int, int] | None`) = `None`: Part of the file the session holds, or `None` when it holds the whole file.

  The part is `(start, end)` in the file's own units. `start` is the first position held; `end` is one past the last.

- **SessionFileView.dataset_id** (`str | None`) = `None`: ID of the dataset that contains the file.

- **SessionFileView.file_id** (`str`): Unique ID of the file, beginning with `fl_`.

- **SessionFileView.ingestable** (`bool | None`) = `None`: Whether the file is meant to be ingested.

  The meaning is the one [`ingestable`](/docs/reference/python-sdk/roboto/domain/files/record#roboto.domain.files.record.FileRecord.ingestable) describes.

- **SessionFileView.ingestion_status** (`roboto.domain.files.IngestionStatus | None`) = `None`: How much of the file's data has been ingested into topics.

- **SessionFileView.max_wall_clock_timestamp_ns** (`int | None`) = `None`: End of the time window of the file the session holds, or `None` when it holds the file's whole time span.

  The end is inclusive, in nanoseconds since the Unix epoch.

- **SessionFileView.min_wall_clock_timestamp_ns** (`int | None`) = `None`: Start of the time window of the file the session holds, or `None` when it holds the file's whole time span.

  The start is inclusive, in nanoseconds since the Unix epoch.

- **SessionFileView.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionFileView.modified** (`datetime.datetime | None`) = `None`: Time the file was last modified.

- **SessionFileView.name** (`str | None`) = `None`: Name of the file, the final component of `relative_path`.

- **SessionFileView.origination** (`str | None`) = `None`: Free-form description of what added the file, such as the SDK version or the user that uploaded it.

- **SessionFileView.relative_path** (`str | None`) = `None`: Path of the file from the root of its dataset's, device's, or organization's files.

- **SessionFileView.size** (`int | None`) = `None`: Size of the file's content in bytes.

- **SessionFileView.tags** (`list[str]`) = `None`: Tags on the file.

- **SessionFileView.unix_epoch_offset_ns** (`int | None`) = `None`: Wall-clock time of time 0 of the file's data the session holds, in nanoseconds since the Unix epoch.

  Roboto added it to the file's own timestamps to compute `min_wall_clock_timestamp_ns` and `max_wall_clock_timestamp_ns`; subtract it from a wall-clock time to read that time in the file's own timestamps. `None` when that data has no registered time span, or when its parts have different offsets.

### SessionIngestionState

```python
class roboto.experimental.sessions.record.SessionIngestionState
```

`from roboto.experimental.sessions import SessionIngestionState`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L192-L206)

Bases: `roboto.compat.StrEnum`

Ingestion state of a session: whether it is in progress, waiting for files to be ingested, or ingested.

Only files that are [`ingestable`](/docs/reference/python-sdk/roboto/domain/files/record#roboto.domain.files.record.FileRecord.ingestable), and that the session was not told to stop waiting for, decide the state.

**Attributes**

- **SessionIngestionState.InProgress** = `'in_progress'`: Session in progress, which Roboto does not announce ingested.
- **SessionIngestionState.Ingested** = `'ingested'`: Complete session whose files it waits for are all ingested.
- **SessionIngestionState.Processing** = `'processing'`: Complete session with at least one file it waits for that is not ingested yet.

### SessionIngestionStatus

```python
class roboto.experimental.sessions.record.SessionIngestionStatus(/, **data: Any)
```

`from roboto.experimental.sessions import SessionIngestionStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L253-L291)

Bases: `pydantic.BaseModel`

Response body of [`ingestion_status()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.ingestion_status).

Ingestion state of a session, with the files it still waits for. Also carried in `SkipWaitingResponse.ingestion`. Files deleted from Roboto are left out of every list and count.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionIngestionStatus.failed_file_count** (`int`) = `0`: Number of files in `pending_files` whose latest ingestion run did not ingest them, so at most 100.

  A run counts when it failed, or finished without ingesting any of the file.

- **SessionIngestionStatus.ingested_file_count** (`int`) = `0`: Number of ingestable files that are ingested.

- **SessionIngestionStatus.ingestion_count** (`int`): Number of times Roboto has announced the session ingested.

- **SessionIngestionStatus.not_ingestable_file_count** (`int`) = `0`: Number of files that are not ingestable, which the session never waits for.

- **SessionIngestionStatus.pending_file_count** (`int`) = `0`: Number of ingestable files not ingested yet that the session waits for.

- **SessionIngestionStatus.pending_files** (`list[PendingIngestionFile]`) = `None`: Ingestable files not ingested yet that the session waits for, the first 100 by path. `pending_file_count` counts them all.

- **SessionIngestionStatus.session_id** (`str`): ID of the session.

- **SessionIngestionStatus.skipped_file_count** (`int`) = `0`: Number of ingestable files not ingested that the session was told to stop waiting for.

- **SessionIngestionStatus.skipped_files** (`list[SkippedIngestionFile]`) = `None`: Ingestable files not ingested that the session was told to stop waiting for, the first 100 by path. `skipped_file_count` counts them all.

- **SessionIngestionStatus.state** (`SessionIngestionState`): Ingestion state of the session: whether it is in progress, waiting for files to be ingested, or ingested.

### SessionIngestionSummary

```python
class roboto.experimental.sessions.record.SessionIngestionSummary(/, **data: Any)
```

`from roboto.experimental.sessions import SessionIngestionSummary`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L294-L318)

Bases: `pydantic.BaseModel`

Ingestion state of one session, in counts.

[`ingestion_summaries()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.ingestion_summaries) returns one per session. Unlike `SessionIngestionStatus`, it lists no files. Files deleted from Roboto are left out of every count.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionIngestionSummary.failed_file_count** (`int`) = `0`: Number of files the session waits for whose latest ingestion run did not ingest them.

  A run counts when it failed, or finished without ingesting any of the file. Only the first 100 files by path that the session waits for are counted.

- **SessionIngestionSummary.ingested_file_count** (`int`) = `0`: Number of ingestable files that are ingested.

- **SessionIngestionSummary.not_ingestable_file_count** (`int`) = `0`: Number of files that are not ingestable, which the session never waits for.

- **SessionIngestionSummary.pending_file_count** (`int`) = `0`: Number of ingestable files not ingested yet that the session waits for.

- **SessionIngestionSummary.session_id** (`str`): ID of the session.

- **SessionIngestionSummary.skipped_file_count** (`int`) = `0`: Number of ingestable files not ingested that the session was told to stop waiting for.

- **SessionIngestionSummary.state** (`SessionIngestionState`): Ingestion state of the session: whether it is in progress, waiting for files to be ingested, or ingested.

### SessionRecord

```python
class roboto.experimental.sessions.record.SessionRecord(/, **data: Any)
```

`from roboto import SessionRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L57-L189)

Bases: `pydantic.BaseModel`

Data record of a session, as the Roboto API returns it.

A session is an operational time window of a device, such as a drone flight, a vehicle drive, or a robot run. It groups the recordings and other data produced during that window, and can span many files or hold only part of one. [`Session`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session) wraps this record with methods that act on the session, and exposes it as [`record`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.record). Building a record raises `pydantic.ValidationError` when `name` is longer than 120 characters.

Roboto announces a complete session ingested, with a `session.ingested` platform event, once every [`ingestable`](/docs/reference/python-sdk/roboto/domain/files/record#roboto.domain.files.record.FileRecord.ingestable) file it waits for is ingested. `ingested_at` and `ingestion_count` record those announcements.

`min_timestamp_ns` and `max_timestamp_ns` span every file the session holds: each file supplies the time window stated for it or, without one, the time span of the data the session takes from it. Roboto recomputes them in the same write as any change to the session's files or to the wall-clock anchors of their data, so they always match the session's files.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionRecord.completed_at** (`datetime.datetime | None`) = `None`: Time the session was last marked complete, or `None` if it never has been.

  Adding a file to a complete session puts it back in progress and keeps this value, so read `status` to tell whether the session is complete now.

- **SessionRecord.completed_by** (`str | None`) = `None`: Principal that last marked the session complete, or `None` if the session never has been.

  The principal is in the same `<type>:<id>` form as `created_by`, and is Roboto's own system user when Roboto made the change.

- **SessionRecord.completes_at** (`datetime.datetime | None`) = `None`: Time Roboto will mark the session complete unless another file is added first.

  `None` while the session is complete, has no completion policy, or has no files.

- **SessionRecord.completion_policy** (`CompletionPolicy | None`) = `None`: Rule by which Roboto marks the session complete on its own, or `None` if the session has none.

  A session without one is marked complete only by request, with [`complete()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.complete).

- **SessionRecord.created** (`datetime.datetime | None`) = `None`: Time the session was created.

- **SessionRecord.created_by** (`str`): Principal that created the session, as `<type>:<id>`, such as `user:<user_id>`.

- **SessionRecord.custom_fields** (`dict[str, Any]`) = `None`: Values of the custom fields the organization defines for sessions, keyed by field name.

  Every session custom field in the [`Ready`](/docs/reference/python-sdk/roboto/domain/custom_fields/record#roboto.domain.custom_fields.record.CustomFieldStatus.Ready) state appears as a key, mapped to `None` when the session has no value for it. Fields in any other state are absent, so the map is empty when no session custom field is in that state.

- **SessionRecord.description** (`str | None`) = `None`: Human-readable description of the session, or `None` if it has none.

- **SessionRecord.ingested_at** (`datetime.datetime | None`) = `None`: Time Roboto last announced the session ingested, or `None` if it never has.

- **SessionRecord.ingestion_count** (`int`) = `0`: Number of times Roboto has announced the session ingested.

  Roboto announces a session again when it is put back in progress and marked complete again, or when its ingestable files change while it is complete, once they are all ingested again. Uploading a file again, removing it, or deleting it changes them; editing a file's tags, metadata, or description does not.

- **SessionRecord.max_timestamp_ns** (`int | None`) = `None`: Latest time covered by the session, in nanoseconds since the Unix epoch.

  `None` while none of its files supplies a time: the session holds no files, or only files added without a time window whose topic data has no time span registered yet.

- **SessionRecord.metadata** (`dict[str, Any]`) = `None`: Key-value metadata on the session.

  Sessions cannot be filtered or sorted by metadata keys. To query a structured attribute of sessions, define a custom field for sessions instead.

- **SessionRecord.min_timestamp_ns** (`int | None`) = `None`: Earliest time covered by the session, in nanoseconds since the Unix epoch.

  `None` while none of its files supplies a time: the session holds no files, or only files added without a time window whose topic data has no time span registered yet.

- **SessionRecord.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionRecord.modified** (`datetime.datetime | None`) = `None`: Time the session was last modified.

- **SessionRecord.modified_by** (`str`): Principal that last modified the session, in the same `<type>:<id>` form as `created_by`.

  It is Roboto's own system user when Roboto made the change.

- **SessionRecord.name** (`str | None`) = `None`: Human-readable name of the session, at most 120 characters, or `None` if it has none.

  Roboto does not require names to be unique.

- **SessionRecord.org_id** (`str`): ID of the organization that owns the session.

- **SessionRecord.session_id** (`str`): Unique ID of the session, beginning with `se_`.

- **SessionRecord.status** (`SessionStatus`): Status of the session: whether more of its files are expected.

  Adding a file to a complete session puts it back in progress.

- **SessionRecord.tags** (`list[str]`) = `None`: Tags on the session.

  A RoboQL query can filter sessions by tag, as in `tags CONTAINS '<tag>'`, but cannot sort them by tag.

### SessionStatus

```python
class roboto.experimental.sessions.record.SessionStatus
```

`from roboto.experimental.sessions import SessionStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L43-L54)

Bases: `roboto.compat.StrEnum`

Status of a session: whether more of its files are expected.

**Attributes**

- **SessionStatus.Complete** = `'complete'`: Session whose files have all been added, marked complete by request or by its completion policy.

  Roboto announces it ingested, with a `session.ingested` platform event, once every ingestable file it waits for is ingested.

- **SessionStatus.InProgress** = `'in_progress'`: Session that may still gain files. Roboto does not announce an in-progress session ingested.

### SessionTopicFieldStats

```python
class roboto.experimental.sessions.record.SessionTopicFieldStats(/, **data: Any)
```

`from roboto.experimental.sessions import SessionTopicFieldStats`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L545-L566)

Bases: `pydantic.BaseModel`

Statistics of one field of a topic over a session's data.

Carried in `SessionTopicStats.fields`.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionTopicFieldStats.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionTopicFieldStats.path** (`roboto.domain.topics.record.FieldPath`): Path of the field in its schema, from the schema root to the leaf.

  For one element of an array field declared with element names, the path is the array's path followed by the element's name, such as `("action", "main_gripper")`.

- **SessionTopicFieldStats.stats** (`dict[str, float]`) = `None`: Each statistic computed for the field, by name.

  A numeric field has `count`, `min`, `max`, `mean`, `median`, `sum`, `stddev`, `p25`, `p75`, `p95` and `p99`; a boolean one has `count`, `true_count` and `false_count`. A statistic that was not computed is absent.

### SessionTopicRecord

```python
class roboto.experimental.sessions.record.SessionTopicRecord(/, **data: Any)
```

`from roboto.experimental.sessions import SessionTopicRecord`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L510-L542)

Bases: [`roboto.domain.topics.TopicIdentityRecord`](/docs/reference/python-sdk/roboto/domain/topics/record#roboto.domain.topics.record.TopicIdentityRecord)

Data record of a topic whose data a session holds, with that data's schemas, time span and counts.

[`list_topics()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.list_topics) yields topics whose `record` is this model.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionTopicRecord.end_time_ns** (`int | None`) = `None`: Latest time of the topic's data in the session, in nanoseconds since the Unix epoch.

  `None` when that data carries no timestamps.

- **SessionTopicRecord.file_count** (`int`) = `0`: Number of the session's files that carry data of the topic.

- **SessionTopicRecord.message_count** (`int | None`) = `None`: Number of messages of the topic the session holds, from the topic statistics Roboto computes for the session.

  `None` until those statistics are computed, when topic statistics are not available in the session's organization, and when the count could not be determined.

- **SessionTopicRecord.schemas** (`list[SessionTopicSchema]`) = `None`: Schemas the topic's data in the session is recorded with; most topics have one.

  They are listed in the order Roboto first ingested the topic's data under each from the session's files.

- **SessionTopicRecord.start_time_ns** (`int | None`) = `None`: Earliest time of the topic's data in the session, in nanoseconds since the Unix epoch.

  `None` when that data carries no timestamps.

### SessionTopicSchema

```python
class roboto.experimental.sessions.record.SessionTopicSchema(/, **data: Any)
```

`from roboto.experimental.sessions import SessionTopicSchema`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L492-L507)

Bases: `pydantic.BaseModel`

Schema that a topic's data in a session is recorded with.

Carried in `SessionTopicRecord.schemas`.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionTopicSchema.checksum** (`str`): Checksum of the schema's fields, unique within an organization.
- **SessionTopicSchema.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- **SessionTopicSchema.name** (`str | None`) = `None`: Name of the schema, such as `"sensor_msgs/msg/Imu"`, or `None` if it was recorded without one.
- **SessionTopicSchema.schema_id** (`str`): Unique ID of the schema.

### SessionTopicStats

```python
class roboto.experimental.sessions.record.SessionTopicStats(/, **data: Any)
```

`from roboto.experimental.sessions import SessionTopicStats`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L569-L588)

Bases: `pydantic.BaseModel`

Response body of [`get_topic_stats()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.get_topic_stats).

Statistics of one topic over a session's data, grouped by field.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionTopicStats.fields** (`list[SessionTopicFieldStats]`) = `None`: One entry per field of the topic that has statistics, ordered by path.

  The elements of a named array are the exception: they follow the array's path in the order its names were declared.

- **SessionTopicStats.message_count** (`int | None`) = `None`: Number of messages of the topic the session holds, or `None` when that count was not computed.

- **SessionTopicStats.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionTopicStats.topic_id** (`str`): ID of the topic.

### SessionTopicStatsRun

```python
class roboto.experimental.sessions.record.SessionTopicStatsRun(/, **data: Any)
```

`from roboto.experimental.sessions import SessionTopicStatsRun`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L621-L647)

Bases: `pydantic.BaseModel`

Response body of [`get_topic_stats_run()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.get_topic_stats_run).

Latest run of the `session_metrics` action that Roboto triggered on a session. Roboto triggers one each time the session is announced ingested, but only while the organization's session-metrics trigger (named `roboto-session-metrics`) is installed and enabled. Runs of the action started by hand are not included.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SessionTopicStatsRun.invocation_id** (`str | None`) = `None`: ID of the action invocation the run started, or `None` when the run has started none.

  It is `None` while Roboto is still starting the run, when no run was triggered, and when Roboto could not start one.

- **SessionTopicStatsRun.model_config**: Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

- **SessionTopicStatsRun.started** (`datetime.datetime | None`) = `None`: Time Roboto last tried to start the run, or `None` when the run is `Scheduled` or `NotRun`.

- **SessionTopicStatsRun.status** (`SessionTopicStatsRunStatus`): Status of the run: where it stands.

  When Roboto triggered no run on the session's latest announcement and none is `Scheduled`, this describes the run on the newest earlier announcement that has one, which computed statistics from the session's files as they were then.

### SessionTopicStatsRunStatus

```python
class roboto.experimental.sessions.record.SessionTopicStatsRunStatus
```

`from roboto.experimental.sessions import SessionTopicStatsRunStatus`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L591-L618)

Bases: `roboto.compat.StrEnum`

Status of a topic statistics run: where the latest run Roboto triggered on a session stands.

**Attributes**

- **SessionTopicStatsRunStatus.Failed** = `'failed'`: The action failed or was cancelled, or Roboto could not start it.

- **SessionTopicStatsRunStatus.Finished** = `'finished'`: The action finished.

  It can leave some topics without statistics: when the session's topics would have more than 10,000 statistics in all, the topics with the most fields are left out until the rest fit.

- **SessionTopicStatsRunStatus.NotRun** = `'not_run'`: No run was triggered for the session.

  For example, the session was never announced ingested, or was announced before Roboto computed topic statistics in its organization.

- **SessionTopicStatsRunStatus.Running** = `'running'`: Roboto is starting the `session_metrics` action, or the action is queued or running.

- **SessionTopicStatsRunStatus.Scheduled** = `'scheduled'`: Roboto has not yet started the run for the session's announcement as ingested in the last five minutes.

  Roboto reports this only while the organization's session-metrics trigger is enabled.

### SkipWaitingResponse

```python
class roboto.experimental.sessions.record.SkipWaitingResponse(/, **data: Any)
```

`from roboto.experimental.sessions import SkipWaitingResponse`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L333-L339)

Bases: `pydantic.BaseModel`

Response body of [`skip_waiting_for()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.skip_waiting_for).

**Parameters**

- **data** (`Any`)

**Attributes**

- **SkipWaitingResponse.ingestion** (`SessionIngestionStatus`): Ingestion state of the session after the skip.
- **SkipWaitingResponse.not_in_session** (`list[str]`) = `None`: IDs of requested files that are not in the session, for which nothing was skipped.

### SkippedIngestionFile

```python
class roboto.experimental.sessions.record.SkippedIngestionFile(/, **data: Any)
```

`from roboto.experimental.sessions import SkippedIngestionFile`

[Source](https://github.com/roboto-ai/roboto-python-sdk/blob/main/src/roboto/experimental/sessions/record.py#L231-L250)

Bases: `pydantic.BaseModel`

Ingestable file of a session that is not ingested, which the session was told to stop waiting for.

Carried in `SessionIngestionStatus.skipped_files`. [`skip_waiting_for()`](/docs/reference/python-sdk/roboto/experimental/sessions/session#roboto.experimental.sessions.session.Session.skip_waiting_for) stops a session waiting for a file. The skip covers the version of the file that was current when it was made: editing the file's tags, metadata, or description keeps it, and uploading the file again ends it.

**Parameters**

- **data** (`Any`)

**Attributes**

- **SkippedIngestionFile.file_id** (`str`): ID of the file.

- **SkippedIngestionFile.relative_path** (`str`): Path of the file from the root of its dataset's, device's, or organization's files.

- **SkippedIngestionFile.skipped_at** (`datetime.datetime | None`) = `None`: Time the session was told to stop waiting for the file.

- **SkippedIngestionFile.skipped_by** (`str | None`) = `None`: Principal that told the session to stop waiting for the file.

  It is written as `<type>:<id>`, such as `user:<user_id>`.
