Class: AWSCDK::Lex::CfnBot::SpeechFoundationModelProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
lex/cfn_bot.rb

Overview

Configuration for a foundation model used for speech synthesis and recognition capabilities.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(model_arn:, voice_id: nil) ⇒ SpeechFoundationModelProperty

Returns a new instance of SpeechFoundationModelProperty.

Parameters:

  • model_arn (String)
  • voice_id (String, nil) (defaults to: nil)

    The identifier of the voice to use for speech synthesis with the foundation model.



6131
6132
6133
6134
6135
6136
# File 'lex/cfn_bot.rb', line 6131

def initialize(model_arn:, voice_id: nil)
  @model_arn = model_arn
  Jsii::Type.check_type(@model_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "modelArn")
  @voice_id = voice_id
  Jsii::Type.check_type(@voice_id, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "voiceId") unless @voice_id.nil?
end

Instance Attribute Details

#model_arnString (readonly)



6140
6141
6142
# File 'lex/cfn_bot.rb', line 6140

def model_arn
  @model_arn
end

#voice_idString? (readonly)

The identifier of the voice to use for speech synthesis with the foundation model.



6145
6146
6147
# File 'lex/cfn_bot.rb', line 6145

def voice_id
  @voice_id
end

Class Method Details

.jsii_propertiesObject



6147
6148
6149
6150
6151
6152
# File 'lex/cfn_bot.rb', line 6147

def self.jsii_properties
  {
    :model_arn => "modelArn",
    :voice_id => "voiceId",
  }
end

Instance Method Details

#to_jsiiObject



6154
6155
6156
6157
6158
6159
6160
6161
# File 'lex/cfn_bot.rb', line 6154

def to_jsii
  result = {}
  result.merge!({
    "modelArn" => @model_arn,
    "voiceId" => @voice_id,
  })
  result.compact
end