GenerativeAISettingsProperty Struct
Contains specifications about the generative AI capabilities from Amazon Bedrock that you can turn on for your bot.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lex as lex } from 'aws-cdk-lib';
const generativeAISettingsProperty: lex.CfnBot.GenerativeAISettingsProperty = {
buildtimeSettings: {
descriptiveBotBuilderSpecification: {
enabled: false,
// the properties below are optional
bedrockModelSpecification: {
modelArn: 'modelArn',
// the properties below are optional
bedrockGuardrailConfiguration: {
bedrockGuardrailIdentifier: 'bedrockGuardrailIdentifier',
bedrockGuardrailVersion: 'bedrockGuardrailVersion',
},
bedrockModelCustomPrompt: 'bedrockModelCustomPrompt',
bedrockTraceStatus: 'bedrockTraceStatus',
},
},
sampleUtteranceGenerationSpecification: {
enabled: false,
// the properties below are optional
bedrockModelSpecification: {
modelArn: 'modelArn',
// the properties below are optional
bedrockGuardrailConfiguration: {
bedrockGuardrailIdentifier: 'bedrockGuardrailIdentifier',
bedrockGuardrailVersion: 'bedrockGuardrailVersion',
},
bedrockModelCustomPrompt: 'bedrockModelCustomPrompt',
bedrockTraceStatus: 'bedrockTraceStatus',
},
},
},
runtimeSettings: {
nluImprovementSpecification: {
enabled: false,
// the properties below are optional
assistedNluMode: 'assistedNluMode',
intentDisambiguationSettings: {
enabled: false,
// the properties below are optional
customDisambiguationMessage: 'customDisambiguationMessage',
maxDisambiguationIntents: 123,
},
},
slotResolutionImprovementSpecification: {
enabled: false,
// the properties below are optional
bedrockModelSpecification: {
modelArn: 'modelArn',
// the properties below are optional
bedrockGuardrailConfiguration: {
bedrockGuardrailIdentifier: 'bedrockGuardrailIdentifier',
bedrockGuardrailVersion: 'bedrockGuardrailVersion',
},
bedrockModelCustomPrompt: 'bedrockModelCustomPrompt',
bedrockTraceStatus: 'bedrockTraceStatus',
},
},
},
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_lex as lex
generative_ai_settings_property = lex.CfnBot.GenerativeAISettingsProperty(
buildtime_settings=lex.CfnBot.BuildtimeSettingsProperty(
descriptive_bot_builder_specification=lex.CfnBot.DescriptiveBotBuilderSpecificationProperty(
enabled=False,
# the properties below are optional
bedrock_model_specification=lex.CfnBot.BedrockModelSpecificationProperty(
model_arn="modelArn",
# the properties below are optional
bedrock_guardrail_configuration=lex.CfnBot.BedrockGuardrailConfigurationProperty(
bedrock_guardrail_identifier="bedrockGuardrailIdentifier",
bedrock_guardrail_version="bedrockGuardrailVersion"
),
bedrock_model_custom_prompt="bedrockModelCustomPrompt",
bedrock_trace_status="bedrockTraceStatus"
)
),
sample_utterance_generation_specification=lex.CfnBot.SampleUtteranceGenerationSpecificationProperty(
enabled=False,
# the properties below are optional
bedrock_model_specification=lex.CfnBot.BedrockModelSpecificationProperty(
model_arn="modelArn",
# the properties below are optional
bedrock_guardrail_configuration=lex.CfnBot.BedrockGuardrailConfigurationProperty(
bedrock_guardrail_identifier="bedrockGuardrailIdentifier",
bedrock_guardrail_version="bedrockGuardrailVersion"
),
bedrock_model_custom_prompt="bedrockModelCustomPrompt",
bedrock_trace_status="bedrockTraceStatus"
)
)
),
runtime_settings=lex.CfnBot.RuntimeSettingsProperty(
nlu_improvement_specification=lex.CfnBot.NluImprovementSpecificationProperty(
enabled=False,
# the properties below are optional
assisted_nlu_mode="assistedNluMode",
intent_disambiguation_settings=lex.CfnBot.IntentDisambiguationSettingsProperty(
enabled=False,
# the properties below are optional
custom_disambiguation_message="customDisambiguationMessage",
max_disambiguation_intents=123
)
),
slot_resolution_improvement_specification=lex.CfnBot.SlotResolutionImprovementSpecificationProperty(
enabled=False,
# the properties below are optional
bedrock_model_specification=lex.CfnBot.BedrockModelSpecificationProperty(
model_arn="modelArn",
# the properties below are optional
bedrock_guardrail_configuration=lex.CfnBot.BedrockGuardrailConfigurationProperty(
bedrock_guardrail_identifier="bedrockGuardrailIdentifier",
bedrock_guardrail_version="bedrockGuardrailVersion"
),
bedrock_model_custom_prompt="bedrockModelCustomPrompt",
bedrock_trace_status="bedrockTraceStatus"
)
)
)
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.lex.*;
GenerativeAISettingsProperty generativeAISettingsProperty = GenerativeAISettingsProperty.builder()
.buildtimeSettings(BuildtimeSettingsProperty.builder()
.descriptiveBotBuilderSpecification(DescriptiveBotBuilderSpecificationProperty.builder()
.enabled(false)
// the properties below are optional
.bedrockModelSpecification(BedrockModelSpecificationProperty.builder()
.modelArn("modelArn")
// the properties below are optional
.bedrockGuardrailConfiguration(BedrockGuardrailConfigurationProperty.builder()
.bedrockGuardrailIdentifier("bedrockGuardrailIdentifier")
.bedrockGuardrailVersion("bedrockGuardrailVersion")
.build())
.bedrockModelCustomPrompt("bedrockModelCustomPrompt")
.bedrockTraceStatus("bedrockTraceStatus")
.build())
.build())
.sampleUtteranceGenerationSpecification(SampleUtteranceGenerationSpecificationProperty.builder()
.enabled(false)
// the properties below are optional
.bedrockModelSpecification(BedrockModelSpecificationProperty.builder()
.modelArn("modelArn")
// the properties below are optional
.bedrockGuardrailConfiguration(BedrockGuardrailConfigurationProperty.builder()
.bedrockGuardrailIdentifier("bedrockGuardrailIdentifier")
.bedrockGuardrailVersion("bedrockGuardrailVersion")
.build())
.bedrockModelCustomPrompt("bedrockModelCustomPrompt")
.bedrockTraceStatus("bedrockTraceStatus")
.build())
.build())
.build())
.runtimeSettings(RuntimeSettingsProperty.builder()
.nluImprovementSpecification(NluImprovementSpecificationProperty.builder()
.enabled(false)
// the properties below are optional
.assistedNluMode("assistedNluMode")
.intentDisambiguationSettings(IntentDisambiguationSettingsProperty.builder()
.enabled(false)
// the properties below are optional
.customDisambiguationMessage("customDisambiguationMessage")
.maxDisambiguationIntents(123)
.build())
.build())
.slotResolutionImprovementSpecification(SlotResolutionImprovementSpecificationProperty.builder()
.enabled(false)
// the properties below are optional
.bedrockModelSpecification(BedrockModelSpecificationProperty.builder()
.modelArn("modelArn")
// the properties below are optional
.bedrockGuardrailConfiguration(BedrockGuardrailConfigurationProperty.builder()
.bedrockGuardrailIdentifier("bedrockGuardrailIdentifier")
.bedrockGuardrailVersion("bedrockGuardrailVersion")
.build())
.bedrockModelCustomPrompt("bedrockModelCustomPrompt")
.bedrockTraceStatus("bedrockTraceStatus")
.build())
.build())
.build())
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Lex;
var generativeAISettingsProperty = new GenerativeAISettingsProperty {
BuildtimeSettings = new BuildtimeSettingsProperty {
DescriptiveBotBuilderSpecification = new DescriptiveBotBuilderSpecificationProperty {
Enabled = false,
// the properties below are optional
BedrockModelSpecification = new BedrockModelSpecificationProperty {
ModelArn = "modelArn",
// the properties below are optional
BedrockGuardrailConfiguration = new BedrockGuardrailConfigurationProperty {
BedrockGuardrailIdentifier = "bedrockGuardrailIdentifier",
BedrockGuardrailVersion = "bedrockGuardrailVersion"
},
BedrockModelCustomPrompt = "bedrockModelCustomPrompt",
BedrockTraceStatus = "bedrockTraceStatus"
}
},
SampleUtteranceGenerationSpecification = new SampleUtteranceGenerationSpecificationProperty {
Enabled = false,
// the properties below are optional
BedrockModelSpecification = new BedrockModelSpecificationProperty {
ModelArn = "modelArn",
// the properties below are optional
BedrockGuardrailConfiguration = new BedrockGuardrailConfigurationProperty {
BedrockGuardrailIdentifier = "bedrockGuardrailIdentifier",
BedrockGuardrailVersion = "bedrockGuardrailVersion"
},
BedrockModelCustomPrompt = "bedrockModelCustomPrompt",
BedrockTraceStatus = "bedrockTraceStatus"
}
}
},
RuntimeSettings = new RuntimeSettingsProperty {
NluImprovementSpecification = new NluImprovementSpecificationProperty {
Enabled = false,
// the properties below are optional
AssistedNluMode = "assistedNluMode",
IntentDisambiguationSettings = new IntentDisambiguationSettingsProperty {
Enabled = false,
// the properties below are optional
CustomDisambiguationMessage = "customDisambiguationMessage",
MaxDisambiguationIntents = 123
}
},
SlotResolutionImprovementSpecification = new SlotResolutionImprovementSpecificationProperty {
Enabled = false,
// the properties below are optional
BedrockModelSpecification = new BedrockModelSpecificationProperty {
ModelArn = "modelArn",
// the properties below are optional
BedrockGuardrailConfiguration = new BedrockGuardrailConfigurationProperty {
BedrockGuardrailIdentifier = "bedrockGuardrailIdentifier",
BedrockGuardrailVersion = "bedrockGuardrailVersion"
},
BedrockModelCustomPrompt = "bedrockModelCustomPrompt",
BedrockTraceStatus = "bedrockTraceStatus"
}
}
}
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
generativeAISettingsProperty := &GenerativeAISettingsProperty{
BuildtimeSettings: &BuildtimeSettingsProperty{
DescriptiveBotBuilderSpecification: &DescriptiveBotBuilderSpecificationProperty{
Enabled: jsii.Boolean(false),
// the properties below are optional
BedrockModelSpecification: &BedrockModelSpecificationProperty{
ModelArn: jsii.String("modelArn"),
// the properties below are optional
BedrockGuardrailConfiguration: &BedrockGuardrailConfigurationProperty{
BedrockGuardrailIdentifier: jsii.String("bedrockGuardrailIdentifier"),
BedrockGuardrailVersion: jsii.String("bedrockGuardrailVersion"),
},
BedrockModelCustomPrompt: jsii.String("bedrockModelCustomPrompt"),
BedrockTraceStatus: jsii.String("bedrockTraceStatus"),
},
},
SampleUtteranceGenerationSpecification: &SampleUtteranceGenerationSpecificationProperty{
Enabled: jsii.Boolean(false),
// the properties below are optional
BedrockModelSpecification: &BedrockModelSpecificationProperty{
ModelArn: jsii.String("modelArn"),
// the properties below are optional
BedrockGuardrailConfiguration: &BedrockGuardrailConfigurationProperty{
BedrockGuardrailIdentifier: jsii.String("bedrockGuardrailIdentifier"),
BedrockGuardrailVersion: jsii.String("bedrockGuardrailVersion"),
},
BedrockModelCustomPrompt: jsii.String("bedrockModelCustomPrompt"),
BedrockTraceStatus: jsii.String("bedrockTraceStatus"),
},
},
},
RuntimeSettings: &RuntimeSettingsProperty{
NluImprovementSpecification: &NluImprovementSpecificationProperty{
Enabled: jsii.Boolean(false),
// the properties below are optional
AssistedNluMode: jsii.String("assistedNluMode"),
IntentDisambiguationSettings: &IntentDisambiguationSettingsProperty{
Enabled: jsii.Boolean(false),
// the properties below are optional
CustomDisambiguationMessage: jsii.String("customDisambiguationMessage"),
MaxDisambiguationIntents: jsii.Number(123),
},
},
SlotResolutionImprovementSpecification: &SlotResolutionImprovementSpecificationProperty{
Enabled: jsii.Boolean(false),
// the properties below are optional
BedrockModelSpecification: &BedrockModelSpecificationProperty{
ModelArn: jsii.String("modelArn"),
// the properties below are optional
BedrockGuardrailConfiguration: &BedrockGuardrailConfigurationProperty{
BedrockGuardrailIdentifier: jsii.String("bedrockGuardrailIdentifier"),
BedrockGuardrailVersion: jsii.String("bedrockGuardrailVersion"),
},
BedrockModelCustomPrompt: jsii.String("bedrockModelCustomPrompt"),
BedrockTraceStatus: jsii.String("bedrockTraceStatus"),
},
},
},
}
Properties
buildtimeSettingsoptionalIResolvable | CfnBot.BuildtimeSettingsPropertybuildtime_settingsoptionaltyping.Union[IResolvable, BuildtimeSettingsProperty]buildtimeSettingsoptionalIResolvableBuildtimeSettingsoptionalIResolvableBuildtimeSettingsoptionalinterface{}#runtimeSettingsoptionalIResolvable | CfnBot.RuntimeSettingsPropertyruntime_settingsoptionaltyping.Union[IResolvable, RuntimeSettingsProperty]runtimeSettingsoptionalIResolvableRuntimeSettingsoptionalIResolvableRuntimeSettingsoptionalinterface{}#