roboto.domain.files.record#

Module Contents#

class roboto.domain.files.record.DirectoryRecord(/, **data)#

Bases: pydantic.BaseModel

Wire-transmissible representation of a directory within a dataset.

DirectoryRecord represents a logical directory structure within a dataset, containing metadata about the directory’s location and contents. Directories are used to organize files hierarchically within datasets.

Directory records are typically returned when browsing dataset contents or when performing directory-based operations like bulk deletion.

Parameters:

data (Any)

association_id: str#
created: datetime.datetime#
created_by: str#
description: str | None = None#
directory_id: str#
fs_type: FSType#
metadata: dict[str, Any] = None#
modified: datetime.datetime#
modified_by: str#
name: str#

Name of the directory (the final component of the path).

org_id: str#
origination: str#
parent_id: str | None = None#
relative_path: str#
status: FileStatus#
storage_type: FileStorageType#
tags: list[str] = None#
upload_id: str#
class roboto.domain.files.record.FSType#

Bases: str, enum.Enum

File system type enum

Directory = 'directory'#
File = 'file'#
class roboto.domain.files.record.FileRecord(/, **data)#

Bases: pydantic.BaseModel

Wire-transmissible representation of a file in the Roboto platform.

FileRecord contains all the metadata and properties associated with a file, including its location, status, ingestion state, and user-defined metadata. This is the data structure used for API communication and persistence.

FileRecord instances are typically created by the platform during file import or upload operations, and are updated as files are processed and modified. The File domain class wraps FileRecord to provide a more convenient interface for file operations.

Parameters:

data (Any)

association_id: str#
property bucket: str#
Return type:

str

created: datetime.datetime#
created_by: str = ''#
description: str | None = None#
device_id: str | None = None#
file_id: str#
fs_type: FSType#
ingestion_status: IngestionStatus#
property key: str#
Return type:

str

metadata: dict[str, Any] = None#
modified: datetime.datetime#
modified_by: str#
name: str#
org_id: str#
origination: str = ''#
parent_id: str | None = None#
relative_path: str#
size: int#
status: FileStatus#
storage_type: FileStorageType#
tags: list[str] = None#
upload_id: str = 'NO_ID'#
uri: str#
version: int#
class roboto.domain.files.record.FileStatus#

Bases: str, enum.Enum

Enumeration of possible file status values in the Roboto platform.

File status tracks the lifecycle state of a file from initial upload through to availability for use. This status is managed automatically by the platform and affects file visibility and accessibility.

The typical file lifecycle is: Reserved → Available → (optionally) Deleted.

Available = 'available'#

File upload is complete and the file is ready for use.

Files with this status are visible in dataset listings, searchable through the query system, and available for download and processing by actions.

Deleted = 'deleted'#

File is marked for deletion and is no longer accessible.

Files with this status are not visible in listings and cannot be accessed. This status may be temporary during the deletion process.

Reserved = 'reserved'#

File upload has been initiated but not yet completed.

Files with this status are not yet available for use and are not visible in dataset listings. This is the initial status when an upload begins.

class roboto.domain.files.record.FileStorageType#

Bases: str, enum.Enum

Enumeration of file storage types in the Roboto platform.

Storage type indicates how the file was added to the platform and affects access patterns and permissions. This information is used internally for credential management and access control.

S3Directory = 'directory'#

This node is a virtual directory.

S3Imported = 'imported'#

File was imported from a read-only customer-managed S3 bucket.

These files remain in the customer’s bucket and are accessed using customer-provided credentials. The customer retains full control over the file storage and access permissions.

S3Uploaded = 'uploaded'#

File was uploaded to a Roboto-managed or customer read/write bucket.

These files were explicitly uploaded through the Roboto platform to either a Roboto-managed bucket or a customer’s bring-your-own read/write bucket. Access is managed through Roboto’s credential system.

class roboto.domain.files.record.FileTag#

Bases: enum.Enum

Enumeration of system-defined file tag types.

These tags are used internally by the platform for indexing and organizing files. They are automatically applied during file operations and should not be manually modified by users.

CommonPrefix = 'common_prefix'#

Tag containing the common path prefix for files in a batch operation.

DatasetId = 'dataset_id'#

Tag containing the ID of the dataset that contains this file.

OrgId = 'org_id'#

Tag containing the organization ID that owns this file.

TransactionId = 'transaction_id'#

Tag containing the transaction ID for files uploaded in a batch.

class roboto.domain.files.record.IngestionStatus#

Bases: str, enum.Enum

Enumeration of file ingestion status values in the Roboto platform.

Ingestion status tracks whether a file’s data has been processed and extracted into topics for analysis and visualization. This status determines what platform features are available for the file and whether it can trigger automated workflows.

File ingestion happens as a post-upload processing step. Roboto supports many common robotics log formats (ROS bags, MCAP files, ULOG files, etc.) out-of-the-box. Custom ingestion actions can be written for other formats.

When writing custom ingestion actions, be sure to update the file’s ingestion status to mark it as fully ingested. This enables triggers and other automated workflows that depend on complete ingestion.

Ingested files have first-class visualization support and can be queried through the topic data system.

Ingested = 'ingested'#

All topics from this file have been fully processed and recorded.

Files with this status have complete topic data available for visualization, analysis, and querying. They are eligible for post-ingestion triggers and automated workflows that depend on complete data extraction.

NotIngested = 'not_ingested'#

No topics from this file have been processed or recorded.

Files with this status have not undergone data extraction. They cannot be visualized through the topic system and are not eligible for topic-based triggers or analysis workflows.

PartlyIngested = 'partly_ingested'#

Some but not all topics from this file have been processed.

Files with this status have at least one topic record but ingestion is incomplete. Some visualization and analysis features may be available, but the file is not yet eligible for post-ingestion triggers.

roboto.domain.files.record.is_directory(record)#
Parameters:

record (FileRecord | DirectoryRecord)

Return type:

TypeGuard[DirectoryRecord]

roboto.domain.files.record.is_file(record)#
Parameters:

record (FileRecord | DirectoryRecord)

Return type:

TypeGuard[FileRecord]