public final class Playbook extends GeneratedMessageV3 implements PlaybookOrBuilder
Playbook is the basic building block to instruct the LLM how to execute a
certain task.
A playbook consists of a goal to accomplish, an optional list of step by step
instructions (the step instruction may refers to name of the custom or
default plugin tools to use) to perform the task,
a list of contextual input data to be passed in at the beginning of the
invoked, and a list of output parameters to store the playbook result.
Protobuf type google.cloud.dialogflow.cx.v3beta1.Playbook
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
CREATE_TIME_FIELD_NUMBER
public static final int CREATE_TIME_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
DISPLAY_NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
GOAL_FIELD_NUMBER
public static final int GOAL_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
public static final int INPUT_PARAMETER_DEFINITIONS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
INSTRUCTION_FIELD_NUMBER
public static final int INSTRUCTION_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
LLM_MODEL_SETTINGS_FIELD_NUMBER
public static final int LLM_MODEL_SETTINGS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
OUTPUT_PARAMETER_DEFINITIONS_FIELD_NUMBER
public static final int OUTPUT_PARAMETER_DEFINITIONS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
REFERENCED_FLOWS_FIELD_NUMBER
public static final int REFERENCED_FLOWS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
REFERENCED_PLAYBOOKS_FIELD_NUMBER
public static final int REFERENCED_PLAYBOOKS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
public static final int REFERENCED_TOOLS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
TOKEN_COUNT_FIELD_NUMBER
public static final int TOKEN_COUNT_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
UPDATE_TIME_FIELD_NUMBER
public static final int UPDATE_TIME_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static Playbook getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static Playbook.Builder newBuilder()
newBuilder(Playbook prototype)
public static Playbook.Builder newBuilder(Playbook prototype)
Parameter |
Name |
Description |
prototype |
Playbook
|
public static Playbook parseDelimitedFrom(InputStream input)
public static Playbook parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static Playbook parseFrom(byte[] data)
Parameter |
Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Playbook parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static Playbook parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Playbook parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Playbook parseFrom(CodedInputStream input)
public static Playbook parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static Playbook parseFrom(InputStream input)
public static Playbook parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static Playbook parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Playbook parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<Playbook> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter |
Name |
Description |
obj |
Object
|
Overrides
getCreateTime()
public Timestamp getCreateTime()
Output only. The timestamp of initial playbook creation.
.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
Timestamp |
The createTime.
|
getCreateTimeOrBuilder()
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The timestamp of initial playbook creation.
.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
getDefaultInstanceForType()
public Playbook getDefaultInstanceForType()
getDisplayName()
public String getDisplayName()
Required. The human-readable name of the playbook, unique within an agent.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
String |
The displayName.
|
getDisplayNameBytes()
public ByteString getDisplayNameBytes()
Required. The human-readable name of the playbook, unique within an agent.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
ByteString |
The bytes for displayName.
|
getGoal()
Required. High level description of the goal the playbook intend to
accomplish.
string goal = 3 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
String |
The goal.
|
getGoalBytes()
public ByteString getGoalBytes()
Required. High level description of the goal the playbook intend to
accomplish.
string goal = 3 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
ByteString |
The bytes for goal.
|
public ParameterDefinition getInputParameterDefinitions(int index)
Optional. Defined structured input parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition input_parameter_definitions = 5 [(.google.api.field_behavior) = OPTIONAL];
Parameter |
Name |
Description |
index |
int
|
public int getInputParameterDefinitionsCount()
Optional. Defined structured input parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition input_parameter_definitions = 5 [(.google.api.field_behavior) = OPTIONAL];
Returns |
Type |
Description |
int |
|
public List<ParameterDefinition> getInputParameterDefinitionsList()
Optional. Defined structured input parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition input_parameter_definitions = 5 [(.google.api.field_behavior) = OPTIONAL];
public ParameterDefinitionOrBuilder getInputParameterDefinitionsOrBuilder(int index)
Optional. Defined structured input parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition input_parameter_definitions = 5 [(.google.api.field_behavior) = OPTIONAL];
Parameter |
Name |
Description |
index |
int
|
public List<? extends ParameterDefinitionOrBuilder> getInputParameterDefinitionsOrBuilderList()
Optional. Defined structured input parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition input_parameter_definitions = 5 [(.google.api.field_behavior) = OPTIONAL];
Returns |
Type |
Description |
List<? extends com.google.cloud.dialogflow.cx.v3beta1.ParameterDefinitionOrBuilder> |
|
getInstruction()
public Playbook.Instruction getInstruction()
Instruction to accomplish target goal.
.google.cloud.dialogflow.cx.v3beta1.Playbook.Instruction instruction = 17;
getInstructionOrBuilder()
public Playbook.InstructionOrBuilder getInstructionOrBuilder()
Instruction to accomplish target goal.
.google.cloud.dialogflow.cx.v3beta1.Playbook.Instruction instruction = 17;
getLlmModelSettings()
public LlmModelSettings getLlmModelSettings()
Optional. Llm model settings for the playbook.
.google.cloud.dialogflow.cx.v3beta1.LlmModelSettings llm_model_settings = 14 [(.google.api.field_behavior) = OPTIONAL];
getLlmModelSettingsOrBuilder()
public LlmModelSettingsOrBuilder getLlmModelSettingsOrBuilder()
Optional. Llm model settings for the playbook.
.google.cloud.dialogflow.cx.v3beta1.LlmModelSettings llm_model_settings = 14 [(.google.api.field_behavior) = OPTIONAL];
getName()
The unique identifier of the playbook.
Format:
projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/playbooks/<PlaybookID>
.
string name = 1;
Returns |
Type |
Description |
String |
The name.
|
getNameBytes()
public ByteString getNameBytes()
The unique identifier of the playbook.
Format:
projects/<ProjectID>/locations/<LocationID>/agents/<AgentID>/playbooks/<PlaybookID>
.
string name = 1;
Returns |
Type |
Description |
ByteString |
The bytes for name.
|
getOutputParameterDefinitions(int index)
public ParameterDefinition getOutputParameterDefinitions(int index)
Optional. Defined structured output parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition output_parameter_definitions = 6 [(.google.api.field_behavior) = OPTIONAL];
Parameter |
Name |
Description |
index |
int
|
getOutputParameterDefinitionsCount()
public int getOutputParameterDefinitionsCount()
Optional. Defined structured output parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition output_parameter_definitions = 6 [(.google.api.field_behavior) = OPTIONAL];
Returns |
Type |
Description |
int |
|
getOutputParameterDefinitionsList()
public List<ParameterDefinition> getOutputParameterDefinitionsList()
Optional. Defined structured output parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition output_parameter_definitions = 6 [(.google.api.field_behavior) = OPTIONAL];
getOutputParameterDefinitionsOrBuilder(int index)
public ParameterDefinitionOrBuilder getOutputParameterDefinitionsOrBuilder(int index)
Optional. Defined structured output parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition output_parameter_definitions = 6 [(.google.api.field_behavior) = OPTIONAL];
Parameter |
Name |
Description |
index |
int
|
getOutputParameterDefinitionsOrBuilderList()
public List<? extends ParameterDefinitionOrBuilder> getOutputParameterDefinitionsOrBuilderList()
Optional. Defined structured output parameters for this playbook.
repeated .google.cloud.dialogflow.cx.v3beta1.ParameterDefinition output_parameter_definitions = 6 [(.google.api.field_behavior) = OPTIONAL];
Returns |
Type |
Description |
List<? extends com.google.cloud.dialogflow.cx.v3beta1.ParameterDefinitionOrBuilder> |
|
getParserForType()
public Parser<Playbook> getParserForType()
Overrides
getReferencedFlows(int index)
public String getReferencedFlows(int index)
Output only. The resource name of flows referenced by the current playbook
in the instructions.
repeated string referenced_flows = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the element to return.
|
Returns |
Type |
Description |
String |
The referencedFlows at the given index.
|
getReferencedFlowsBytes(int index)
public ByteString getReferencedFlowsBytes(int index)
Output only. The resource name of flows referenced by the current playbook
in the instructions.
repeated string referenced_flows = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the value to return.
|
Returns |
Type |
Description |
ByteString |
The bytes of the referencedFlows at the given index.
|
getReferencedFlowsCount()
public int getReferencedFlowsCount()
Output only. The resource name of flows referenced by the current playbook
in the instructions.
repeated string referenced_flows = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Returns |
Type |
Description |
int |
The count of referencedFlows.
|
getReferencedFlowsList()
public ProtocolStringList getReferencedFlowsList()
Output only. The resource name of flows referenced by the current playbook
in the instructions.
repeated string referenced_flows = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
getReferencedPlaybooks(int index)
public String getReferencedPlaybooks(int index)
Output only. The resource name of other playbooks referenced by the current
playbook in the instructions.
repeated string referenced_playbooks = 11 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the element to return.
|
Returns |
Type |
Description |
String |
The referencedPlaybooks at the given index.
|
getReferencedPlaybooksBytes(int index)
public ByteString getReferencedPlaybooksBytes(int index)
Output only. The resource name of other playbooks referenced by the current
playbook in the instructions.
repeated string referenced_playbooks = 11 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the value to return.
|
Returns |
Type |
Description |
ByteString |
The bytes of the referencedPlaybooks at the given index.
|
getReferencedPlaybooksCount()
public int getReferencedPlaybooksCount()
Output only. The resource name of other playbooks referenced by the current
playbook in the instructions.
repeated string referenced_playbooks = 11 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
Returns |
Type |
Description |
int |
The count of referencedPlaybooks.
|
getReferencedPlaybooksList()
public ProtocolStringList getReferencedPlaybooksList()
Output only. The resource name of other playbooks referenced by the current
playbook in the instructions.
repeated string referenced_playbooks = 11 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
public String getReferencedTools(int index)
Optional. The resource name of tools referenced by the current playbook in
the instructions. If not provided explicitly, they are will
be implied using the tool being referenced in goal and steps.
repeated string referenced_tools = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the element to return.
|
Returns |
Type |
Description |
String |
The referencedTools at the given index.
|
public ByteString getReferencedToolsBytes(int index)
Optional. The resource name of tools referenced by the current playbook in
the instructions. If not provided explicitly, they are will
be implied using the tool being referenced in goal and steps.
repeated string referenced_tools = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }
Parameter |
Name |
Description |
index |
int
The index of the value to return.
|
Returns |
Type |
Description |
ByteString |
The bytes of the referencedTools at the given index.
|
public int getReferencedToolsCount()
Optional. The resource name of tools referenced by the current playbook in
the instructions. If not provided explicitly, they are will
be implied using the tool being referenced in goal and steps.
repeated string referenced_tools = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }
Returns |
Type |
Description |
int |
The count of referencedTools.
|
public ProtocolStringList getReferencedToolsList()
Optional. The resource name of tools referenced by the current playbook in
the instructions. If not provided explicitly, they are will
be implied using the tool being referenced in goal and steps.
repeated string referenced_tools = 13 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }
getSerializedSize()
public int getSerializedSize()
Returns |
Type |
Description |
int |
|
Overrides
getTokenCount()
public long getTokenCount()
Output only. Estimated number of tokes current playbook takes when sent to
the LLM.
int64 token_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
long |
The tokenCount.
|
getUpdateTime()
public Timestamp getUpdateTime()
Output only. Last time the playbook version was updated.
.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
Timestamp |
The updateTime.
|
getUpdateTimeOrBuilder()
public TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. Last time the playbook version was updated.
.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasCreateTime()
public boolean hasCreateTime()
Output only. The timestamp of initial playbook creation.
.google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
boolean |
Whether the createTime field is set.
|
hasInstruction()
public boolean hasInstruction()
Instruction to accomplish target goal.
.google.cloud.dialogflow.cx.v3beta1.Playbook.Instruction instruction = 17;
Returns |
Type |
Description |
boolean |
Whether the instruction field is set.
|
hasLlmModelSettings()
public boolean hasLlmModelSettings()
Optional. Llm model settings for the playbook.
.google.cloud.dialogflow.cx.v3beta1.LlmModelSettings llm_model_settings = 14 [(.google.api.field_behavior) = OPTIONAL];
Returns |
Type |
Description |
boolean |
Whether the llmModelSettings field is set.
|
hasUpdateTime()
public boolean hasUpdateTime()
Output only. Last time the playbook version was updated.
.google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
boolean |
Whether the updateTime field is set.
|
hashCode()
Returns |
Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public Playbook.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected Playbook.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Returns |
Type |
Description |
Object |
|
Overrides
toBuilder()
public Playbook.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides