Class Experiment (1.24.0)

Experiment(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Represents an experiment in an environment.


name str
The name of the experiment. Format: projects/
display_name str
Required. The human-readable name of the experiment (unique in an environment). Limit of 64 characters.
description str
The human-readable description of the experiment.
The current state of the experiment. Transition triggered by Experiments.StartExperiment: DRAFT->RUNNING. Transition triggered by Experiments.CancelExperiment: DRAFT->DONE or RUNNING->DONE.
The definition of the experiment.
The configuration for auto rollout. If set, there should be exactly two variants in the experiment (control variant being the default version of the flow), the traffic allocation for the non-control variant will gradually increase to 100% when conditions are met, and eventually replace the control variant to become the default version of the flow.
State of the auto rollout process.
rollout_failure_reason str
The reason why rollout has failed. Should only be set when state is ROLLOUT_FAILED.
Inference result of the experiment.
create_time google.protobuf.timestamp_pb2.Timestamp
Creation time of this experiment.
start_time google.protobuf.timestamp_pb2.Timestamp
Start time of this experiment.
end_time google.protobuf.timestamp_pb2.Timestamp
End time of this experiment.
last_update_time google.protobuf.timestamp_pb2.Timestamp
Last update time of this experiment.
experiment_length google.protobuf.duration_pb2.Duration
Maximum number of days to run the experiment/rollout. If auto-rollout is not enabled, default value and maximum will be 30 days. If auto-rollout is enabled, default value and maximum will be 6 days.
variants_history MutableSequence[]
The history of updates to the experiment variants.



Definition(mapping=None, *, ignore_unknown_fields=False, **kwargs)


Result(mapping=None, *, ignore_unknown_fields=False, **kwargs)

The inference result which includes an objective metric to optimize and the confidence interval.



The state of the experiment.

Values: STATE_UNSPECIFIED (0): State unspecified. DRAFT (1): The experiment is created but not started yet. RUNNING (2): The experiment is running. DONE (3): The experiment is done. ROLLOUT_FAILED (4): The experiment with auto-rollout enabled has failed.