Experiments
Experiment
Bases: Protocol
Defines a namespace for organizing machine learning models with scoped uniqueness.
An Experiment groups related models while ensuring model identifiers remain unique within its namespace. Provides globally unique identification via UUID and a human-readable locally unique name.
id
property
Globally unique inmutable identifier for the experiment.
Returns:
| Name | Type | Description |
|---|---|---|
UUID |
UUID
|
Unique identifier that can be used across systems. |
models
property
Each experiment owns a collection of models. The models' identifiers are unique under an experiment namespace.
Returns:
| Name | Type | Description |
|---|---|---|
Models |
Models
|
The collection of models owned by the experiment. |
name
property
Human-readable identifier unique within the users's scope.
Used for intuitive referencing an experiment while enforcing uniqueness constraints at the user's level.
Returns:
| Name | Type | Description |
|---|---|---|
str |
str
|
The name of the experiment. |
Experiments
Bases: ABC
An abstract base class representing a collection of experiments. This class serves as an interface for available backends or as a base class for a custom implementation.
In order to create a concrete instance of an experiment collection, use the getallexperiments
accessor.
Methods:
| Name | Description |
|---|---|
create |
Creates a new experiment with the given name. |
read |
Retrieves an experiment by its name if any. |
update |
Updates an experiment's name. |
delete |
Deletes an experiment by ID. |
list |
List all experiments in the collection. |
create(name)
abstractmethod
Creates an experiment with a given name
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
The name and unique identifier of the experiment |
required |
Returns:
| Type | Description |
|---|---|
Experiment
|
Optional[Experiment]: The created experiment. |
delete(id)
abstractmethod
Deletes the experiment with the given ID.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
id
|
UUID
|
The ID of the experiment to be retrieved. |
required |
list()
abstractmethod
List the experiments in the collection.
Returns:
| Type | Description |
|---|---|
list[Experiment]
|
List[Experiment]: The list of experiments in the collection. |
read(name)
abstractmethod
Retrieve an experiment by it's name
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
The name of the experiment to be retrieved. |
required |
Returns:
| Type | Description |
|---|---|
Optional[Experiment]
|
Optional[Experiment]: The experiment with the given name if any. |
update(id, name)
abstractmethod
Updates the name of an experiment.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
id
|
UUID
|
The ID of the experiment to update. |
required |
name
|
str
|
The new name of the experiment. |
required |