Class: AWSCDK::Lex::CfnBot::CustomVocabularyItemProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Lex::CfnBot::CustomVocabularyItemProperty
- Defined in:
- lex/cfn_bot.rb
Overview
Specifies an entry in a custom vocabulary.
Instance Attribute Summary collapse
-
#display_as ⇒ String?
readonly
The DisplayAs value for the custom vocabulary item from the custom vocabulary list.
-
#phrase ⇒ String
readonly
Specifies 1 - 4 words that should be recognized.
-
#weight ⇒ Numeric?
readonly
Specifies the degree to which the phrase recognition is boosted.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(phrase:, display_as: nil, weight: nil) ⇒ CustomVocabularyItemProperty
constructor
A new instance of CustomVocabularyItemProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(phrase:, display_as: nil, weight: nil) ⇒ CustomVocabularyItemProperty
Returns a new instance of CustomVocabularyItemProperty.
1955 1956 1957 1958 1959 1960 1961 1962 |
# File 'lex/cfn_bot.rb', line 1955 def initialize(phrase:, display_as: nil, weight: nil) @phrase = phrase Jsii::Type.check_type(@phrase, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "phrase") @display_as = display_as Jsii::Type.check_type(@display_as, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "displayAs") unless @display_as.nil? @weight = weight Jsii::Type.check_type(@weight, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "weight") unless @weight.nil? end |
Instance Attribute Details
#display_as ⇒ String? (readonly)
The DisplayAs value for the custom vocabulary item from the custom vocabulary list.
1973 1974 1975 |
# File 'lex/cfn_bot.rb', line 1973 def display_as @display_as end |
#phrase ⇒ String (readonly)
Specifies 1 - 4 words that should be recognized.
1968 1969 1970 |
# File 'lex/cfn_bot.rb', line 1968 def phrase @phrase end |
#weight ⇒ Numeric? (readonly)
Specifies the degree to which the phrase recognition is boosted.
The default value is 1.
1980 1981 1982 |
# File 'lex/cfn_bot.rb', line 1980 def weight @weight end |
Class Method Details
.jsii_properties ⇒ Object
1982 1983 1984 1985 1986 1987 1988 |
# File 'lex/cfn_bot.rb', line 1982 def self.jsii_properties { :phrase => "phrase", :display_as => "displayAs", :weight => "weight", } end |
Instance Method Details
#to_jsii ⇒ Object
1990 1991 1992 1993 1994 1995 1996 1997 1998 |
# File 'lex/cfn_bot.rb', line 1990 def to_jsii result = {} result.merge!({ "phrase" => @phrase, "displayAs" => @display_as, "weight" => @weight, }) result.compact end |