@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class PromptConfiguration extends Object implements Serializable, Cloneable, StructuredPojo
Contains configurations to override a prompt template in one part of an agent sequence. For more information, see Advanced prompts.
Constructor and Description |
---|
PromptConfiguration() |
Modifier and Type | Method and Description |
---|---|
PromptConfiguration |
clone() |
boolean |
equals(Object obj) |
String |
getBasePromptTemplate()
Defines the prompt template with which to replace the default prompt template.
|
InferenceConfiguration |
getInferenceConfiguration()
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the
promptType . |
String |
getParserMode()
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the
promptType . |
String |
getPromptCreationMode()
Specifies whether to override the default prompt template for this
promptType . |
String |
getPromptState()
Specifies whether to allow the agent to carry out the step specified in the
promptType . |
String |
getPromptType()
The step in the agent sequence that this prompt configuration applies to.
|
int |
hashCode() |
void |
marshall(ProtocolMarshaller protocolMarshaller)
Marshalls this structured data using the given
ProtocolMarshaller . |
void |
setBasePromptTemplate(String basePromptTemplate)
Defines the prompt template with which to replace the default prompt template.
|
void |
setInferenceConfiguration(InferenceConfiguration inferenceConfiguration)
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the
promptType . |
void |
setParserMode(String parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the
promptType . |
void |
setPromptCreationMode(String promptCreationMode)
Specifies whether to override the default prompt template for this
promptType . |
void |
setPromptState(String promptState)
Specifies whether to allow the agent to carry out the step specified in the
promptType . |
void |
setPromptType(String promptType)
The step in the agent sequence that this prompt configuration applies to.
|
String |
toString()
Returns a string representation of this object.
|
PromptConfiguration |
withBasePromptTemplate(String basePromptTemplate)
Defines the prompt template with which to replace the default prompt template.
|
PromptConfiguration |
withInferenceConfiguration(InferenceConfiguration inferenceConfiguration)
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the
promptType . |
PromptConfiguration |
withParserMode(CreationMode parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the
promptType . |
PromptConfiguration |
withParserMode(String parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the
promptType . |
PromptConfiguration |
withPromptCreationMode(CreationMode promptCreationMode)
Specifies whether to override the default prompt template for this
promptType . |
PromptConfiguration |
withPromptCreationMode(String promptCreationMode)
Specifies whether to override the default prompt template for this
promptType . |
PromptConfiguration |
withPromptState(PromptState promptState)
Specifies whether to allow the agent to carry out the step specified in the
promptType . |
PromptConfiguration |
withPromptState(String promptState)
Specifies whether to allow the agent to carry out the step specified in the
promptType . |
PromptConfiguration |
withPromptType(PromptType promptType)
The step in the agent sequence that this prompt configuration applies to.
|
PromptConfiguration |
withPromptType(String promptType)
The step in the agent sequence that this prompt configuration applies to.
|
public void setBasePromptTemplate(String basePromptTemplate)
Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see Prompt template placeholder variables. For more information, see Configure the prompt templates.
basePromptTemplate
- Defines the prompt template with which to replace the default prompt template. You can use placeholder
variables in the base prompt template to customize the prompt. For more information, see Prompt template
placeholder variables. For more information, see Configure the
prompt templates.public String getBasePromptTemplate()
Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see Prompt template placeholder variables. For more information, see Configure the prompt templates.
public PromptConfiguration withBasePromptTemplate(String basePromptTemplate)
Defines the prompt template with which to replace the default prompt template. You can use placeholder variables in the base prompt template to customize the prompt. For more information, see Prompt template placeholder variables. For more information, see Configure the prompt templates.
basePromptTemplate
- Defines the prompt template with which to replace the default prompt template. You can use placeholder
variables in the base prompt template to customize the prompt. For more information, see Prompt template
placeholder variables. For more information, see Configure the
prompt templates.public void setInferenceConfiguration(InferenceConfiguration inferenceConfiguration)
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the promptType
. For more information, see Inference parameters for
foundation models.
inferenceConfiguration
- Contains inference parameters to use when the agent invokes a foundation model in the part of the agent
sequence defined by the promptType
. For more information, see Inference parameters for
foundation models.public InferenceConfiguration getInferenceConfiguration()
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the promptType
. For more information, see Inference parameters for
foundation models.
promptType
. For more information, see Inference parameters
for foundation models.public PromptConfiguration withInferenceConfiguration(InferenceConfiguration inferenceConfiguration)
Contains inference parameters to use when the agent invokes a foundation model in the part of the agent sequence
defined by the promptType
. For more information, see Inference parameters for
foundation models.
inferenceConfiguration
- Contains inference parameters to use when the agent invokes a foundation model in the part of the agent
sequence defined by the promptType
. For more information, see Inference parameters for
foundation models.public void setParserMode(String parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.
parserMode
- Specifies whether to override the default parser Lambda function when parsing the raw foundation model
output in the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.CreationMode
public String getParserMode()
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.
promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.CreationMode
public PromptConfiguration withParserMode(String parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.
parserMode
- Specifies whether to override the default parser Lambda function when parsing the raw foundation model
output in the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.CreationMode
public PromptConfiguration withParserMode(CreationMode parserMode)
Specifies whether to override the default parser Lambda function when parsing the raw foundation model output in
the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.
parserMode
- Specifies whether to override the default parser Lambda function when parsing the raw foundation model
output in the part of the agent sequence defined by the promptType
. If you set the field as
OVERRIDEN
, the overrideLambda
field in the PromptOverrideConfiguration must be specified with the ARN of a Lambda function.CreationMode
public void setPromptCreationMode(String promptCreationMode)
Specifies whether to override the default prompt template for this promptType
. Set this value to
OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If you leave
it as DEFAULT
, the agent uses a default prompt template.
promptCreationMode
- Specifies whether to override the default prompt template for this promptType
. Set this value
to OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If
you leave it as DEFAULT
, the agent uses a default prompt template.CreationMode
public String getPromptCreationMode()
Specifies whether to override the default prompt template for this promptType
. Set this value to
OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If you leave
it as DEFAULT
, the agent uses a default prompt template.
promptType
. Set this
value to OVERRIDDEN
to use the prompt that you provide in the
basePromptTemplate
. If you leave it as DEFAULT
, the agent uses a default prompt
template.CreationMode
public PromptConfiguration withPromptCreationMode(String promptCreationMode)
Specifies whether to override the default prompt template for this promptType
. Set this value to
OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If you leave
it as DEFAULT
, the agent uses a default prompt template.
promptCreationMode
- Specifies whether to override the default prompt template for this promptType
. Set this value
to OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If
you leave it as DEFAULT
, the agent uses a default prompt template.CreationMode
public PromptConfiguration withPromptCreationMode(CreationMode promptCreationMode)
Specifies whether to override the default prompt template for this promptType
. Set this value to
OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If you leave
it as DEFAULT
, the agent uses a default prompt template.
promptCreationMode
- Specifies whether to override the default prompt template for this promptType
. Set this value
to OVERRIDDEN
to use the prompt that you provide in the basePromptTemplate
. If
you leave it as DEFAULT
, the agent uses a default prompt template.CreationMode
public void setPromptState(String promptState)
Specifies whether to allow the agent to carry out the step specified in the promptType
. If you set
this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
promptState
- Specifies whether to allow the agent to carry out the step specified in the promptType
. If
you set this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
PromptState
public String getPromptState()
Specifies whether to allow the agent to carry out the step specified in the promptType
. If you set
this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
promptType
. If
you set this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
PromptState
public PromptConfiguration withPromptState(String promptState)
Specifies whether to allow the agent to carry out the step specified in the promptType
. If you set
this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
promptState
- Specifies whether to allow the agent to carry out the step specified in the promptType
. If
you set this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
PromptState
public PromptConfiguration withPromptState(PromptState promptState)
Specifies whether to allow the agent to carry out the step specified in the promptType
. If you set
this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
promptState
- Specifies whether to allow the agent to carry out the step specified in the promptType
. If
you set this value to DISABLED
, the agent skips that step. The default state for each
promptType
is as follows.
PRE_PROCESSING
– ENABLED
ORCHESTRATION
– ENABLED
KNOWLEDGE_BASE_RESPONSE_GENERATION
– ENABLED
POST_PROCESSING
– DISABLED
PromptState
public void setPromptType(String promptType)
The step in the agent sequence that this prompt configuration applies to.
promptType
- The step in the agent sequence that this prompt configuration applies to.PromptType
public String getPromptType()
The step in the agent sequence that this prompt configuration applies to.
PromptType
public PromptConfiguration withPromptType(String promptType)
The step in the agent sequence that this prompt configuration applies to.
promptType
- The step in the agent sequence that this prompt configuration applies to.PromptType
public PromptConfiguration withPromptType(PromptType promptType)
The step in the agent sequence that this prompt configuration applies to.
promptType
- The step in the agent sequence that this prompt configuration applies to.PromptType
public String toString()
toString
in class Object
Object.toString()
public PromptConfiguration clone()
public void marshall(ProtocolMarshaller protocolMarshaller)
StructuredPojo
ProtocolMarshaller
.marshall
in interface StructuredPojo
protocolMarshaller
- Implementation of ProtocolMarshaller
used to marshall this object's data.