- Resource: LabsExperimentExecution
- State
- LabsExperimentExecutionContext
- ExperimentExecutionStage
- ExperimentExecutionStageOutput
- ExperimentExecutionStageRenderingType
- AgenticContext
- LabsChatMessage
- Visibility
- Methods
Resource: LabsExperimentExecution
The experiment execution resource, contains execution context and results of an experiment.
| JSON representation |
|---|
{ "name": string, "createTime": string, "endTime": string, "lastUpdateTime": string, "state": enum ( |
| Fields | |
|---|---|
name |
Identifier. The unique identifier of the ExperimentExecution. As this is a child of an Experiment, the name of the Experiment is included in the name. Format: projects/{project}/locations/{location}/instances/{instance}/labsExperiments/{labsExperiment}/executions/{labsExperimentExecution} |
createTime |
Output only. When the execution request was initially received by the Labs Service. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
endTime |
Output only. When the execution reached a terminal state (SUCCESS, FAILURE, TIMEOUT, etc.). nil if the execution is still in progress. Output only. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
lastUpdateTime |
Output only. When the execution state (status, message) was last modified. Useful for tracking progress and concurrency control. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
state |
Output only. The current lifecycle state of the execution. |
stateMessage |
Output only. An optional, user-friendly message describing the current state or progress. Example: "Processing step 2/3: Calling external API..." |
context |
Output only. The final result payload if the execution completed successfully (state is SUCCESS). Stored as a generic Struct to accommodate varied structures from different experiments. |
State
The status of the experiment execution.
| Enums | |
|---|---|
STATE_UNSPECIFIED |
Default unspecified status. |
QUEUED |
Execution is queued and waiting to be processed. |
RUNNING |
Execution is actively being processed by a worker. |
SUCCEEDED |
Execution completed successfully and produced a result. |
FAILED |
Execution failed due to an error within the experiment logic or infrastructure issue. |
TIMED_OUT |
Executin failed because it exceeded the configured timeout limit. |
CANCELLED |
Execution was cancelled (e.g., by user request). |
LabsExperimentExecutionContext
The execution context for an Experiment. Defines inputs, outputs, and other metadata for an Experiment execution.
| JSON representation |
|---|
{ "stages": [ { object ( |
| Fields | |
|---|---|
stages[] |
Output only. The stages of the execution. This is used when type is |
agenticContext |
Output only. Context for AGENTIC experiments. This is used when type is |
ExperimentExecutionStage
A definition of a stage in the execution.
| JSON representation |
|---|
{
"name": string,
"current": boolean,
"inputs": {
object
},
"outputs": [
{
object ( |
| Fields | |
|---|---|
name |
Required. The unique identifier of the stage. |
current |
Optional. Is the stage the current stage of the execution. |
inputs |
Required. Thze input payload of the stage. |
outputs[] |
Output only. The output payload of the stage. |
ExperimentExecutionStageOutput
Defines the outputs of a stage.
| JSON representation |
|---|
{ "renderType": enum ( |
| Fields | |
|---|---|
renderType |
Output only. The type of the stage output. |
name |
Output only. The unique name/identifier for the output of the stage output. |
Union field payload. The payload of the stage output. payload can be only one of the following: |
|
text |
Output only. The text payload of the stage output. Matches a markdown, Json, and code. |
generativeUiSchema |
Output only. A UI schema for a generative UI output. This is used to render the message in the UI. |
ExperimentExecutionStageRenderingType
Defines the rendering type in the UI of a stage output. New values may be added in the future. Clients should be prepared to handle unknown enum values gracefully.
| Enums | |
|---|---|
EXPERIMENT_EXECUTION_STAGE_RENDERING_TYPE_UNSPECIFIED |
Default unspecified stage output type. |
MARKDOWN |
The stage output is a chat/conversation output. |
CODE |
The stage output is a code output. |
JSON |
The stage output is a JSON output. |
GENERATIVE |
The stage output is a generative UI output. |
AgenticContext
Context specific to AGENTIC experiments.
| JSON representation |
|---|
{
"sessionId": string,
"messages": [
{
object ( |
| Fields | |
|---|---|
sessionId |
Output only. Metadata related to the Agent Hub. |
messages[] |
Output only. The history of messages in the agentic session. |
LabsChatMessage
Represents a single message in a chat conversation.
| JSON representation |
|---|
{
"role": string,
"text": string,
"visibility": enum ( |
| Fields | |
|---|---|
role |
Output only. The role of the message sender. Allowed values are "user", and "agent". |
text |
Output only. The text content of the message. |
visibility |
Output only. The visibility state of the message. |
generativeUiSchema |
Output only. Generative UI representation of the message. This is used to render the message in the UI. |
Visibility
Controls the visibility of the message in the UI.
| Enums | |
|---|---|
VISIBILITY_UNSPECIFIED |
Visibility is unspecified. |
VISIBLE |
Message is fully shown. |
HIDDEN |
Message is hidden from the UI. |
Methods |
|
|---|---|
|
Retrieves a specific LabsExperimentExecution resource. |
|
Lists LabsExperimentExecution resources. |
|
Updates a LabsExperimentExecution. |