Class: Google::Apis::DiscoveryengineV1beta::GoogleCloudDiscoveryengineV1betaCompletionSuggestion
- Inherits:
-
Object
- Object
- Google::Apis::DiscoveryengineV1beta::GoogleCloudDiscoveryengineV1betaCompletionSuggestion
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/discoveryengine_v1beta/classes.rb,
lib/google/apis/discoveryengine_v1beta/representations.rb,
lib/google/apis/discoveryengine_v1beta/representations.rb
Overview
Autocomplete suggestions that are imported from Customer.
Instance Attribute Summary collapse
-
#alternative_phrases ⇒ Array<String>
Alternative matching phrases for this suggestion.
-
#frequency ⇒ Fixnum
Frequency of this suggestion.
-
#global_score ⇒ Float
Global score of this suggestion.
-
#group_id ⇒ String
If two suggestions have the same groupId, they will not be returned together.
-
#group_score ⇒ Float
The score of this suggestion within its group.
-
#language_code ⇒ String
BCP-47 language code of this suggestion.
-
#suggestion ⇒ String
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1betaCompletionSuggestion
constructor
A new instance of GoogleCloudDiscoveryengineV1betaCompletionSuggestion.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudDiscoveryengineV1betaCompletionSuggestion
Returns a new instance of GoogleCloudDiscoveryengineV1betaCompletionSuggestion.
23082 23083 23084 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23082 def initialize(**args) update!(**args) end |
Instance Attribute Details
#alternative_phrases ⇒ Array<String>
Alternative matching phrases for this suggestion.
Corresponds to the JSON property alternativePhrases
23046 23047 23048 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23046 def alternative_phrases @alternative_phrases end |
#frequency ⇒ Fixnum
Frequency of this suggestion. Will be used to rank suggestions when score is
not available.
Corresponds to the JSON property frequency
23052 23053 23054 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23052 def frequency @frequency end |
#global_score ⇒ Float
Global score of this suggestion. Control how this suggestion would be scored /
ranked.
Corresponds to the JSON property globalScore
23058 23059 23060 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23058 def global_score @global_score end |
#group_id ⇒ String
If two suggestions have the same groupId, they will not be returned together.
Instead the one ranked higher will be returned. This can be used to
deduplicate semantically identical suggestions.
Corresponds to the JSON property groupId
23065 23066 23067 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23065 def group_id @group_id end |
#group_score ⇒ Float
The score of this suggestion within its group.
Corresponds to the JSON property groupScore
23070 23071 23072 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23070 def group_score @group_score end |
#language_code ⇒ String
BCP-47 language code of this suggestion.
Corresponds to the JSON property languageCode
23075 23076 23077 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23075 def language_code @language_code end |
#suggestion ⇒ String
Required. The suggestion text.
Corresponds to the JSON property suggestion
23080 23081 23082 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23080 def suggestion @suggestion end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
23087 23088 23089 23090 23091 23092 23093 23094 23095 |
# File 'lib/google/apis/discoveryengine_v1beta/classes.rb', line 23087 def update!(**args) @alternative_phrases = args[:alternative_phrases] if args.key?(:alternative_phrases) @frequency = args[:frequency] if args.key?(:frequency) @global_score = args[:global_score] if args.key?(:global_score) @group_id = args[:group_id] if args.key?(:group_id) @group_score = args[:group_score] if args.key?(:group_score) @language_code = args[:language_code] if args.key?(:language_code) @suggestion = args[:suggestion] if args.key?(:suggestion) end |