google-cloud-discovery_engine-v1 2.0.0 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/client.rb +186 -4
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/client.rb +181 -4
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/service_stub.rb +72 -0
- data/lib/google/cloud/discovery_engine/v1/document_service/client.rb +8 -2
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/client.rb +8 -2
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/client.rb +1 -3
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest/client.rb +1 -3
- data/lib/google/cloud/discovery_engine/v1/rank_service/client.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1/rank_service/rest/client.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1/recommendation_service/client.rb +3 -3
- data/lib/google/cloud/discovery_engine/v1/recommendation_service/rest/client.rb +3 -3
- data/lib/google/cloud/discovery_engine/v1/rest.rb +1 -0
- data/lib/google/cloud/discovery_engine/v1/search_service/client.rb +44 -12
- data/lib/google/cloud/discovery_engine/v1/search_service/rest/client.rb +44 -12
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/client.rb +484 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/credentials.rb +47 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/paths.rb +101 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/rest/client.rb +451 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/rest/service_stub.rb +159 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service/rest.rb +53 -0
- data/lib/google/cloud/discovery_engine/v1/serving_config_service.rb +56 -0
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/client.rb +316 -3
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/paths.rb +49 -0
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/client.rb +295 -3
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/service_stub.rb +206 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/client.rb +21 -9
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/client.rb +21 -9
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/service_stub.rb +8 -0
- data/lib/google/cloud/discovery_engine/v1/version.rb +1 -1
- data/lib/google/cloud/discovery_engine/v1.rb +1 -0
- data/lib/google/cloud/discoveryengine/v1/answer_pb.rb +4 -1
- data/lib/google/cloud/discoveryengine/v1/common_pb.rb +4 -1
- data/lib/google/cloud/discoveryengine/v1/control_pb.rb +7 -1
- data/lib/google/cloud/discoveryengine/v1/conversational_search_service_pb.rb +12 -1
- data/lib/google/cloud/discoveryengine/v1/conversational_search_service_services_pb.rb +8 -0
- data/lib/google/cloud/discoveryengine/v1/data_store_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/document_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/engine_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_pb.rb +6 -1
- data/lib/google/cloud/discoveryengine/v1/import_config_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/safety_pb.rb +47 -0
- data/lib/google/cloud/discoveryengine/v1/search_service_pb.rb +5 -1
- data/lib/google/cloud/discoveryengine/v1/serving_config_pb.rb +52 -0
- data/lib/google/cloud/discoveryengine/v1/serving_config_service_pb.rb +51 -0
- data/lib/google/cloud/discoveryengine/v1/serving_config_service_services_pb.rb +48 -0
- data/lib/google/cloud/discoveryengine/v1/session_pb.rb +3 -1
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_service_pb.rb +10 -1
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_service_services_pb.rb +7 -0
- data/lib/google/cloud/discoveryengine/v1/user_event_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_service_pb.rb +1 -1
- data/proto_docs/google/api/client.rb +6 -0
- data/proto_docs/google/cloud/discoveryengine/v1/answer.rb +53 -2
- data/proto_docs/google/cloud/discoveryengine/v1/chunk.rb +2 -1
- data/proto_docs/google/cloud/discoveryengine/v1/common.rb +40 -0
- data/proto_docs/google/cloud/discoveryengine/v1/control.rb +122 -7
- data/proto_docs/google/cloud/discoveryengine/v1/conversational_search_service.rb +159 -2
- data/proto_docs/google/cloud/discoveryengine/v1/data_store.rb +25 -4
- data/proto_docs/google/cloud/discoveryengine/v1/document.rb +7 -2
- data/proto_docs/google/cloud/discoveryengine/v1/document_service.rb +1 -1
- data/proto_docs/google/cloud/discoveryengine/v1/engine.rb +16 -3
- data/proto_docs/google/cloud/discoveryengine/v1/grounded_generation_service.rb +90 -12
- data/proto_docs/google/cloud/discoveryengine/v1/import_config.rb +19 -1
- data/proto_docs/google/cloud/discoveryengine/v1/purge_config.rb +9 -5
- data/proto_docs/google/cloud/discoveryengine/v1/rank_service.rb +3 -1
- data/proto_docs/google/cloud/discoveryengine/v1/recommendation_service.rb +3 -3
- data/proto_docs/google/cloud/discoveryengine/v1/safety.rb +108 -0
- data/proto_docs/google/cloud/discoveryengine/v1/search_service.rb +109 -8
- data/proto_docs/google/cloud/discoveryengine/v1/serving_config.rb +261 -0
- data/proto_docs/google/cloud/discoveryengine/v1/serving_config_service.rb +44 -0
- data/proto_docs/google/cloud/discoveryengine/v1/session.rb +18 -0
- data/proto_docs/google/cloud/discoveryengine/v1/site_search_engine.rb +19 -2
- data/proto_docs/google/cloud/discoveryengine/v1/site_search_engine_service.rb +146 -4
- data/proto_docs/google/cloud/discoveryengine/v1/user_event.rb +34 -0
- data/proto_docs/google/cloud/discoveryengine/v1/user_event_service.rb +12 -4
- metadata +17 -3
@@ -32,9 +32,16 @@ module Google
|
|
32
32
|
# @!attribute [rw] answer_text
|
33
33
|
# @return [::String]
|
34
34
|
# The textual answer.
|
35
|
+
# @!attribute [rw] grounding_score
|
36
|
+
# @return [::Float]
|
37
|
+
# A score in the range of [0, 1] describing how grounded the answer is by the
|
38
|
+
# reference chunks.
|
35
39
|
# @!attribute [rw] citations
|
36
40
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Citation>]
|
37
41
|
# Citations.
|
42
|
+
# @!attribute [rw] grounding_supports
|
43
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::GroundingSupport>]
|
44
|
+
# Optional. Grounding supports.
|
38
45
|
# @!attribute [rw] references
|
39
46
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::Reference>]
|
40
47
|
# References.
|
@@ -57,6 +64,9 @@ module Google
|
|
57
64
|
# @!attribute [r] complete_time
|
58
65
|
# @return [::Google::Protobuf::Timestamp]
|
59
66
|
# Output only. Answer completed timestamp.
|
67
|
+
# @!attribute [rw] safety_ratings
|
68
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::SafetyRating>]
|
69
|
+
# Optional. Safety ratings.
|
60
70
|
class Answer
|
61
71
|
include ::Google::Protobuf::MessageExts
|
62
72
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -65,10 +75,13 @@ module Google
|
|
65
75
|
# @!attribute [rw] start_index
|
66
76
|
# @return [::Integer]
|
67
77
|
# Index indicates the start of the segment, measured in bytes (UTF-8
|
68
|
-
# unicode).
|
78
|
+
# unicode). If there are multi-byte characters,such as non-ASCII
|
79
|
+
# characters, the index measurement is longer than the string length.
|
69
80
|
# @!attribute [rw] end_index
|
70
81
|
# @return [::Integer]
|
71
|
-
# End of the attributed segment, exclusive.
|
82
|
+
# End of the attributed segment, exclusive. Measured in bytes (UTF-8
|
83
|
+
# unicode). If there are multi-byte characters,such as non-ASCII
|
84
|
+
# characters, the index measurement is longer than the string length.
|
72
85
|
# @!attribute [rw] sources
|
73
86
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>]
|
74
87
|
# Citation sources for the attributed segment.
|
@@ -86,6 +99,35 @@ module Google
|
|
86
99
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
87
100
|
end
|
88
101
|
|
102
|
+
# Grounding support for a claim in `answer_text`.
|
103
|
+
# @!attribute [rw] start_index
|
104
|
+
# @return [::Integer]
|
105
|
+
# Required. Index indicates the start of the claim, measured in bytes
|
106
|
+
# (UTF-8 unicode).
|
107
|
+
# @!attribute [rw] end_index
|
108
|
+
# @return [::Integer]
|
109
|
+
# Required. End of the claim, exclusive.
|
110
|
+
# @!attribute [rw] grounding_score
|
111
|
+
# @return [::Float]
|
112
|
+
# A score in the range of [0, 1] describing how grounded is a specific
|
113
|
+
# claim by the references.
|
114
|
+
# Higher value means that the claim is better supported by the reference
|
115
|
+
# chunks.
|
116
|
+
# @!attribute [rw] grounding_check_required
|
117
|
+
# @return [::Boolean]
|
118
|
+
# Indicates that this claim required grounding check. When the
|
119
|
+
# system decided this claim didn't require attribution/grounding check,
|
120
|
+
# this field is set to false. In that case, no grounding check was
|
121
|
+
# done for the claim and therefore `grounding_score`, `sources` is not
|
122
|
+
# returned.
|
123
|
+
# @!attribute [rw] sources
|
124
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Answer::CitationSource>]
|
125
|
+
# Optional. Citation sources for the claim.
|
126
|
+
class GroundingSupport
|
127
|
+
include ::Google::Protobuf::MessageExts
|
128
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
129
|
+
end
|
130
|
+
|
89
131
|
# Reference.
|
90
132
|
# @!attribute [rw] unstructured_document_info
|
91
133
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::UnstructuredDocumentInfo]
|
@@ -198,6 +240,12 @@ module Google
|
|
198
240
|
# @!attribute [rw] struct_data
|
199
241
|
# @return [::Google::Protobuf::Struct]
|
200
242
|
# Structured search data.
|
243
|
+
# @!attribute [r] title
|
244
|
+
# @return [::String]
|
245
|
+
# Output only. The title of the document.
|
246
|
+
# @!attribute [r] uri
|
247
|
+
# @return [::String]
|
248
|
+
# Output only. The URI of the document.
|
201
249
|
class StructuredDocumentInfo
|
202
250
|
include ::Google::Protobuf::MessageExts
|
203
251
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -379,6 +427,9 @@ module Google
|
|
379
427
|
|
380
428
|
# Answer generation has succeeded.
|
381
429
|
SUCCEEDED = 3
|
430
|
+
|
431
|
+
# Answer generation is currently in progress.
|
432
|
+
STREAMING = 4
|
382
433
|
end
|
383
434
|
|
384
435
|
# An enum for answer skipped reasons.
|
@@ -42,7 +42,8 @@ module Google
|
|
42
42
|
# Output only. Represents the relevance score based on similarity.
|
43
43
|
# Higher score indicates higher chunk relevance.
|
44
44
|
# The score is in range [-1.0, 1.0].
|
45
|
-
# Only populated on
|
45
|
+
# Only populated on
|
46
|
+
# {::Google::Cloud::DiscoveryEngine::V1::SearchResponse SearchResponse}.
|
46
47
|
# @!attribute [rw] document_metadata
|
47
48
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Chunk::DocumentMetadata]
|
48
49
|
# Metadata of the document from the current chunk.
|
@@ -104,11 +104,51 @@ module Google
|
|
104
104
|
# or if
|
105
105
|
# {::Google::Cloud::DiscoveryEngine::V1::UserEvent#direct_user_request UserEvent.direct_user_request}
|
106
106
|
# is set.
|
107
|
+
# @!attribute [rw] time_zone
|
108
|
+
# @return [::String]
|
109
|
+
# Optional. IANA time zone, e.g. Europe/Budapest.
|
107
110
|
class UserInfo
|
108
111
|
include ::Google::Protobuf::MessageExts
|
109
112
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
110
113
|
end
|
111
114
|
|
115
|
+
# Double list.
|
116
|
+
# @!attribute [rw] values
|
117
|
+
# @return [::Array<::Float>]
|
118
|
+
# Double values.
|
119
|
+
class DoubleList
|
120
|
+
include ::Google::Protobuf::MessageExts
|
121
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
122
|
+
end
|
123
|
+
|
124
|
+
# Promotion proto includes uri and other helping information to display the
|
125
|
+
# promotion.
|
126
|
+
# @!attribute [rw] title
|
127
|
+
# @return [::String]
|
128
|
+
# Required. The title of the promotion.
|
129
|
+
# Maximum length: 160 characters.
|
130
|
+
# @!attribute [rw] uri
|
131
|
+
# @return [::String]
|
132
|
+
# Optional. The URL for the page the user wants to promote. Must be set for
|
133
|
+
# site search. For other verticals, this is optional.
|
134
|
+
# @!attribute [rw] image_uri
|
135
|
+
# @return [::String]
|
136
|
+
# Optional. The promotion thumbnail image url.
|
137
|
+
# @!attribute [rw] description
|
138
|
+
# @return [::String]
|
139
|
+
# Optional. The Promotion description.
|
140
|
+
# Maximum length: 200 characters.
|
141
|
+
# @!attribute [rw] enabled
|
142
|
+
# @return [::Boolean]
|
143
|
+
# Optional. The enabled promotion will be returned for any serving configs
|
144
|
+
# associated with the parent of the control this promotion is attached to.
|
145
|
+
#
|
146
|
+
# This flag is used for basic site search only.
|
147
|
+
class SearchLinkPromotion
|
148
|
+
include ::Google::Protobuf::MessageExts
|
149
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
150
|
+
end
|
151
|
+
|
112
152
|
# The industry vertical associated with the
|
113
153
|
# {::Google::Cloud::DiscoveryEngine::V1::DataStore DataStore}.
|
114
154
|
module IndustryVertical
|
@@ -83,29 +83,36 @@ module Google
|
|
83
83
|
|
84
84
|
# Defines a conditioned behavior to employ during serving.
|
85
85
|
# Must be attached to a
|
86
|
-
#
|
86
|
+
# {::Google::Cloud::DiscoveryEngine::V1::ServingConfig ServingConfig} to be
|
87
87
|
# considered at serving time. Permitted actions dependent on `SolutionType`.
|
88
88
|
# @!attribute [rw] boost_action
|
89
89
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction]
|
90
90
|
# Defines a boost-type control
|
91
91
|
#
|
92
|
-
# Note: The following fields are mutually exclusive: `boost_action`, `filter_action`, `redirect_action`, `synonyms_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
92
|
+
# Note: The following fields are mutually exclusive: `boost_action`, `filter_action`, `redirect_action`, `synonyms_action`, `promote_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
93
93
|
# @!attribute [rw] filter_action
|
94
94
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::FilterAction]
|
95
95
|
# Defines a filter-type control
|
96
96
|
# Currently not supported by Recommendation
|
97
97
|
#
|
98
|
-
# Note: The following fields are mutually exclusive: `filter_action`, `boost_action`, `redirect_action`, `synonyms_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
98
|
+
# Note: The following fields are mutually exclusive: `filter_action`, `boost_action`, `redirect_action`, `synonyms_action`, `promote_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
99
99
|
# @!attribute [rw] redirect_action
|
100
100
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::RedirectAction]
|
101
101
|
# Defines a redirect-type control.
|
102
102
|
#
|
103
|
-
# Note: The following fields are mutually exclusive: `redirect_action`, `boost_action`, `filter_action`, `synonyms_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
103
|
+
# Note: The following fields are mutually exclusive: `redirect_action`, `boost_action`, `filter_action`, `synonyms_action`, `promote_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
104
104
|
# @!attribute [rw] synonyms_action
|
105
105
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::SynonymsAction]
|
106
106
|
# Treats a group of terms as synonyms of one another.
|
107
107
|
#
|
108
|
-
# Note: The following fields are mutually exclusive: `synonyms_action`, `boost_action`, `filter_action`, `redirect_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
108
|
+
# Note: The following fields are mutually exclusive: `synonyms_action`, `boost_action`, `filter_action`, `redirect_action`, `promote_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
109
|
+
# @!attribute [rw] promote_action
|
110
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::PromoteAction]
|
111
|
+
# Promote certain links based on predefined trigger queries.
|
112
|
+
#
|
113
|
+
# This now only supports basic site search.
|
114
|
+
#
|
115
|
+
# Note: The following fields are mutually exclusive: `promote_action`, `boost_action`, `filter_action`, `redirect_action`, `synonyms_action`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
109
116
|
# @!attribute [rw] name
|
110
117
|
# @return [::String]
|
111
118
|
# Immutable. Fully qualified name
|
@@ -119,7 +126,7 @@ module Google
|
|
119
126
|
# @!attribute [r] associated_serving_config_ids
|
120
127
|
# @return [::Array<::String>]
|
121
128
|
# Output only. List of all
|
122
|
-
#
|
129
|
+
# {::Google::Cloud::DiscoveryEngine::V1::ServingConfig ServingConfig} IDs this
|
123
130
|
# control is attached to. May take up to 10 minutes to update after changes.
|
124
131
|
# @!attribute [rw] solution_type
|
125
132
|
# @return [::Google::Cloud::DiscoveryEngine::V1::SolutionType]
|
@@ -148,9 +155,22 @@ module Google
|
|
148
155
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
149
156
|
|
150
157
|
# Adjusts order of products in returned list.
|
158
|
+
# @!attribute [rw] fixed_boost
|
159
|
+
# @return [::Float]
|
160
|
+
# Optional. Strength of the boost, which should be in [-1, 1]. Negative
|
161
|
+
# boost means demotion. Default is 0.0 (No-op).
|
162
|
+
#
|
163
|
+
# Note: The following fields are mutually exclusive: `fixed_boost`, `interpolation_boost_spec`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
164
|
+
# @!attribute [rw] interpolation_boost_spec
|
165
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction::InterpolationBoostSpec]
|
166
|
+
# Optional. Complex specification for custom ranking based on customer
|
167
|
+
# defined attribute value.
|
168
|
+
#
|
169
|
+
# Note: The following fields are mutually exclusive: `interpolation_boost_spec`, `fixed_boost`. If a field in that set is populated, all other fields in the set will automatically be cleared.
|
151
170
|
# @!attribute [rw] boost
|
171
|
+
# @deprecated This field is deprecated and may be removed in the next major version update.
|
152
172
|
# @return [::Float]
|
153
|
-
#
|
173
|
+
# Strength of the boost, which should be in [-1, 1]. Negative
|
154
174
|
# boost means demotion. Default is 0.0 (No-op).
|
155
175
|
# @!attribute [rw] filter
|
156
176
|
# @return [::String]
|
@@ -169,6 +189,86 @@ module Google
|
|
169
189
|
class BoostAction
|
170
190
|
include ::Google::Protobuf::MessageExts
|
171
191
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
192
|
+
|
193
|
+
# Specification for custom ranking based on customer specified attribute
|
194
|
+
# value. It provides more controls for customized ranking than the simple
|
195
|
+
# (condition, boost) combination above.
|
196
|
+
# @!attribute [rw] field_name
|
197
|
+
# @return [::String]
|
198
|
+
# Optional. The name of the field whose value will be used to determine
|
199
|
+
# the boost amount.
|
200
|
+
# @!attribute [rw] attribute_type
|
201
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction::InterpolationBoostSpec::AttributeType]
|
202
|
+
# Optional. The attribute type to be used to determine the boost amount.
|
203
|
+
# The attribute value can be derived from the field value of the
|
204
|
+
# specified field_name. In the case of numerical it is straightforward
|
205
|
+
# i.e. attribute_value = numerical_field_value. In the case of freshness
|
206
|
+
# however, attribute_value = (time.now() - datetime_field_value).
|
207
|
+
# @!attribute [rw] interpolation_type
|
208
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction::InterpolationBoostSpec::InterpolationType]
|
209
|
+
# Optional. The interpolation type to be applied to connect the control
|
210
|
+
# points listed below.
|
211
|
+
# @!attribute [rw] control_points
|
212
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction::InterpolationBoostSpec::ControlPoint>]
|
213
|
+
# Optional. The control points used to define the curve. The monotonic
|
214
|
+
# function (defined through the interpolation_type above) passes through
|
215
|
+
# the control points listed here.
|
216
|
+
class InterpolationBoostSpec
|
217
|
+
include ::Google::Protobuf::MessageExts
|
218
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
219
|
+
|
220
|
+
# The control points used to define the curve. The curve defined
|
221
|
+
# through these control points can only be monotonically increasing
|
222
|
+
# or decreasing(constant values are acceptable).
|
223
|
+
# @!attribute [rw] attribute_value
|
224
|
+
# @return [::String]
|
225
|
+
# Optional. Can be one of:
|
226
|
+
# 1. The numerical field value.
|
227
|
+
# 2. The duration spec for freshness:
|
228
|
+
# The value must be formatted as an XSD `dayTimeDuration` value (a
|
229
|
+
# restricted subset of an ISO 8601 duration value). The pattern for
|
230
|
+
# this is: `[nD][T[nH][nM][nS]]`.
|
231
|
+
# @!attribute [rw] boost_amount
|
232
|
+
# @return [::Float]
|
233
|
+
# Optional. The value between -1 to 1 by which to boost the score if
|
234
|
+
# the attribute_value evaluates to the value specified above.
|
235
|
+
class ControlPoint
|
236
|
+
include ::Google::Protobuf::MessageExts
|
237
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
238
|
+
end
|
239
|
+
|
240
|
+
# The attribute(or function) for which the custom ranking is to be
|
241
|
+
# applied.
|
242
|
+
module AttributeType
|
243
|
+
# Unspecified AttributeType.
|
244
|
+
ATTRIBUTE_TYPE_UNSPECIFIED = 0
|
245
|
+
|
246
|
+
# The value of the numerical field will be used to dynamically update
|
247
|
+
# the boost amount. In this case, the attribute_value (the x value)
|
248
|
+
# of the control point will be the actual value of the numerical
|
249
|
+
# field for which the boost_amount is specified.
|
250
|
+
NUMERICAL = 1
|
251
|
+
|
252
|
+
# For the freshness use case the attribute value will be the duration
|
253
|
+
# between the current time and the date in the datetime field
|
254
|
+
# specified. The value must be formatted as an XSD `dayTimeDuration`
|
255
|
+
# value (a restricted subset of an ISO 8601 duration value). The
|
256
|
+
# pattern for this is: `[nD][T[nH][nM][nS]]`.
|
257
|
+
# For example, `5D`, `3DT12H30M`, `T24H`.
|
258
|
+
FRESHNESS = 2
|
259
|
+
end
|
260
|
+
|
261
|
+
# The interpolation type to be applied. Default will be linear
|
262
|
+
# (Piecewise Linear).
|
263
|
+
module InterpolationType
|
264
|
+
# Interpolation type is unspecified. In this case, it defaults to
|
265
|
+
# Linear.
|
266
|
+
INTERPOLATION_TYPE_UNSPECIFIED = 0
|
267
|
+
|
268
|
+
# Piecewise linear interpolation will be applied.
|
269
|
+
LINEAR = 1
|
270
|
+
end
|
271
|
+
end
|
172
272
|
end
|
173
273
|
|
174
274
|
# Specified which products may be included in results.
|
@@ -219,6 +319,21 @@ module Google
|
|
219
319
|
include ::Google::Protobuf::MessageExts
|
220
320
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
221
321
|
end
|
322
|
+
|
323
|
+
# Promote certain links based on some trigger queries.
|
324
|
+
#
|
325
|
+
# Example: Promote shoe store link when searching for `shoe` keyword.
|
326
|
+
# The link can be outside of associated data store.
|
327
|
+
# @!attribute [rw] data_store
|
328
|
+
# @return [::String]
|
329
|
+
# Required. Data store with which this promotion is attached to.
|
330
|
+
# @!attribute [rw] search_link_promotion
|
331
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::SearchLinkPromotion]
|
332
|
+
# Required. Promotion attached to this action.
|
333
|
+
class PromoteAction
|
334
|
+
include ::Google::Protobuf::MessageExts
|
335
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
336
|
+
end
|
222
337
|
end
|
223
338
|
end
|
224
339
|
end
|
@@ -252,6 +252,9 @@ module Google
|
|
252
252
|
# @!attribute [rw] related_questions_spec
|
253
253
|
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::RelatedQuestionsSpec]
|
254
254
|
# Related questions specification.
|
255
|
+
# @!attribute [rw] grounding_spec
|
256
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::GroundingSpec]
|
257
|
+
# Optional. Grounding specification.
|
255
258
|
# @!attribute [rw] answer_generation_spec
|
256
259
|
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::AnswerGenerationSpec]
|
257
260
|
# Answer generation specification.
|
@@ -306,18 +309,63 @@ module Google
|
|
306
309
|
# See [Google Cloud
|
307
310
|
# Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements)
|
308
311
|
# for more details.
|
312
|
+
# @!attribute [rw] end_user_spec
|
313
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::EndUserSpec]
|
314
|
+
# Optional. End user specification.
|
309
315
|
class AnswerQueryRequest
|
310
316
|
include ::Google::Protobuf::MessageExts
|
311
317
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
312
318
|
|
313
319
|
# Safety specification.
|
320
|
+
# There are two use cases:
|
321
|
+
# 1. when only safety_spec.enable is set, the BLOCK_LOW_AND_ABOVE threshold
|
322
|
+
# will be applied for all categories.
|
323
|
+
# 2. when safety_spec.enable is set and some safety_settings are set, only
|
324
|
+
# specified safety_settings are applied.
|
314
325
|
# @!attribute [rw] enable
|
315
326
|
# @return [::Boolean]
|
316
327
|
# Enable the safety filtering on the answer response. It is false by
|
317
328
|
# default.
|
329
|
+
# @!attribute [rw] safety_settings
|
330
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SafetySpec::SafetySetting>]
|
331
|
+
# Optional. Safety settings.
|
332
|
+
# This settings are effective only when the safety_spec.enable is true.
|
318
333
|
class SafetySpec
|
319
334
|
include ::Google::Protobuf::MessageExts
|
320
335
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
336
|
+
|
337
|
+
# Safety settings.
|
338
|
+
# @!attribute [rw] category
|
339
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::HarmCategory]
|
340
|
+
# Required. Harm category.
|
341
|
+
# @!attribute [rw] threshold
|
342
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SafetySpec::SafetySetting::HarmBlockThreshold]
|
343
|
+
# Required. The harm block threshold.
|
344
|
+
class SafetySetting
|
345
|
+
include ::Google::Protobuf::MessageExts
|
346
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
347
|
+
|
348
|
+
# Probability based thresholds levels for blocking.
|
349
|
+
module HarmBlockThreshold
|
350
|
+
# Unspecified harm block threshold.
|
351
|
+
HARM_BLOCK_THRESHOLD_UNSPECIFIED = 0
|
352
|
+
|
353
|
+
# Block low threshold and above (i.e. block more).
|
354
|
+
BLOCK_LOW_AND_ABOVE = 1
|
355
|
+
|
356
|
+
# Block medium threshold and above.
|
357
|
+
BLOCK_MEDIUM_AND_ABOVE = 2
|
358
|
+
|
359
|
+
# Block only high threshold (i.e. block less).
|
360
|
+
BLOCK_ONLY_HIGH = 3
|
361
|
+
|
362
|
+
# Block none.
|
363
|
+
BLOCK_NONE = 4
|
364
|
+
|
365
|
+
# Turn off the safety filter.
|
366
|
+
OFF = 5
|
367
|
+
end
|
368
|
+
end
|
321
369
|
end
|
322
370
|
|
323
371
|
# Related questions specification.
|
@@ -329,6 +377,35 @@ module Google
|
|
329
377
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
330
378
|
end
|
331
379
|
|
380
|
+
# Grounding specification.
|
381
|
+
# @!attribute [rw] include_grounding_supports
|
382
|
+
# @return [::Boolean]
|
383
|
+
# Optional. Specifies whether to include grounding_supports in the answer.
|
384
|
+
# The default value is `false`.
|
385
|
+
#
|
386
|
+
# When this field is set to `true`, returned answer will have
|
387
|
+
# `grounding_score` and will contain GroundingSupports for each claim.
|
388
|
+
# @!attribute [rw] filtering_level
|
389
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::GroundingSpec::FilteringLevel]
|
390
|
+
# Optional. Specifies whether to enable the filtering based on grounding
|
391
|
+
# score and at what level.
|
392
|
+
class GroundingSpec
|
393
|
+
include ::Google::Protobuf::MessageExts
|
394
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
395
|
+
|
396
|
+
# Level to filter based on answer grounding.
|
397
|
+
module FilteringLevel
|
398
|
+
# Default is no filter
|
399
|
+
FILTERING_LEVEL_UNSPECIFIED = 0
|
400
|
+
|
401
|
+
# Filter answers based on a low threshold.
|
402
|
+
FILTERING_LEVEL_LOW = 1
|
403
|
+
|
404
|
+
# Filter answers based on a high threshold.
|
405
|
+
FILTERING_LEVEL_HIGH = 2
|
406
|
+
end
|
407
|
+
end
|
408
|
+
|
332
409
|
# Answer generation specification.
|
333
410
|
# @!attribute [rw] model_spec
|
334
411
|
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::AnswerGenerationSpec::ModelSpec]
|
@@ -612,6 +689,10 @@ module Google
|
|
612
689
|
# @!attribute [rw] query_rephraser_spec
|
613
690
|
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::QueryUnderstandingSpec::QueryRephraserSpec]
|
614
691
|
# Query rephraser specification.
|
692
|
+
# @!attribute [rw] disable_spell_correction
|
693
|
+
# @return [::Boolean]
|
694
|
+
# Optional. Whether to disable spell correction.
|
695
|
+
# The default value is `false`.
|
615
696
|
class QueryUnderstandingSpec
|
616
697
|
include ::Google::Protobuf::MessageExts
|
617
698
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -652,9 +733,76 @@ module Google
|
|
652
733
|
# Max rephrase steps.
|
653
734
|
# The max number is 5 steps.
|
654
735
|
# If not set or set to < 1, it will be set to 1 by default.
|
736
|
+
# @!attribute [rw] model_spec
|
737
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::QueryUnderstandingSpec::QueryRephraserSpec::ModelSpec]
|
738
|
+
# Optional. Query Rephraser Model specification.
|
655
739
|
class QueryRephraserSpec
|
656
740
|
include ::Google::Protobuf::MessageExts
|
657
741
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
742
|
+
|
743
|
+
# Query Rephraser Model specification.
|
744
|
+
# @!attribute [rw] model_type
|
745
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::QueryUnderstandingSpec::QueryRephraserSpec::ModelSpec::ModelType]
|
746
|
+
# Optional. Enabled query rephraser model type. If not set, it will use
|
747
|
+
# LARGE by default.
|
748
|
+
class ModelSpec
|
749
|
+
include ::Google::Protobuf::MessageExts
|
750
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
751
|
+
|
752
|
+
# Query rephraser types. Currently only supports single-hop
|
753
|
+
# (max_rephrase_steps = 1) model selections. For multi-hop
|
754
|
+
# (max_rephrase_steps > 1), there is only one default model.
|
755
|
+
module ModelType
|
756
|
+
# Unspecified model type.
|
757
|
+
MODEL_TYPE_UNSPECIFIED = 0
|
758
|
+
|
759
|
+
# Small query rephraser model. Gemini 1.0 XS model.
|
760
|
+
SMALL = 1
|
761
|
+
|
762
|
+
# Large query rephraser model. Gemini 1.0 Pro model.
|
763
|
+
LARGE = 2
|
764
|
+
end
|
765
|
+
end
|
766
|
+
end
|
767
|
+
end
|
768
|
+
|
769
|
+
# End user specification.
|
770
|
+
# @!attribute [rw] end_user_metadata
|
771
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::EndUserSpec::EndUserMetaData>]
|
772
|
+
# Optional. End user metadata.
|
773
|
+
class EndUserSpec
|
774
|
+
include ::Google::Protobuf::MessageExts
|
775
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
776
|
+
|
777
|
+
# End user metadata.
|
778
|
+
# @!attribute [rw] chunk_info
|
779
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::EndUserSpec::EndUserMetaData::ChunkInfo]
|
780
|
+
# Chunk information.
|
781
|
+
class EndUserMetaData
|
782
|
+
include ::Google::Protobuf::MessageExts
|
783
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
784
|
+
|
785
|
+
# Chunk information.
|
786
|
+
# @!attribute [rw] content
|
787
|
+
# @return [::String]
|
788
|
+
# Chunk textual content. It is limited to 8000 characters.
|
789
|
+
# @!attribute [rw] document_metadata
|
790
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::EndUserSpec::EndUserMetaData::ChunkInfo::DocumentMetadata]
|
791
|
+
# Metadata of the document from the current chunk.
|
792
|
+
class ChunkInfo
|
793
|
+
include ::Google::Protobuf::MessageExts
|
794
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
795
|
+
|
796
|
+
# Document metadata contains the information of the document of
|
797
|
+
# the current chunk.
|
798
|
+
# @!attribute [rw] title
|
799
|
+
# @return [::String]
|
800
|
+
# Title of the document.
|
801
|
+
class DocumentMetadata
|
802
|
+
include ::Google::Protobuf::MessageExts
|
803
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
804
|
+
end
|
805
|
+
end
|
658
806
|
end
|
659
807
|
end
|
660
808
|
|
@@ -751,6 +899,10 @@ module Google
|
|
751
899
|
# @return [::String]
|
752
900
|
# Required. The resource name of the Session to get. Format:
|
753
901
|
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/sessions/{session_id}`
|
902
|
+
# @!attribute [rw] include_answer_details
|
903
|
+
# @return [::Boolean]
|
904
|
+
# Optional. If set to true, the full session including all answer details
|
905
|
+
# will be returned.
|
754
906
|
class GetSessionRequest
|
755
907
|
include ::Google::Protobuf::MessageExts
|
756
908
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -781,13 +933,18 @@ module Google
|
|
781
933
|
# A comma-separated list of fields to order by, sorted in ascending order.
|
782
934
|
# Use "desc" after a field name for descending.
|
783
935
|
# Supported fields:
|
936
|
+
#
|
784
937
|
# * `update_time`
|
785
938
|
# * `create_time`
|
786
939
|
# * `session_name`
|
940
|
+
# * `is_pinned`
|
787
941
|
#
|
788
942
|
# Example:
|
789
|
-
#
|
790
|
-
# "
|
943
|
+
#
|
944
|
+
# * "update_time desc"
|
945
|
+
# * "create_time"
|
946
|
+
# * "is_pinned desc,update_time desc": list sessions by is_pinned first, then
|
947
|
+
# by update_time.
|
791
948
|
class ListSessionsRequest
|
792
949
|
include ::Google::Protobuf::MessageExts
|
793
950
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -50,7 +50,7 @@ module Google
|
|
50
50
|
# @!attribute [r] default_schema_id
|
51
51
|
# @return [::String]
|
52
52
|
# Output only. The id of the default
|
53
|
-
# {::Google::Cloud::DiscoveryEngine::V1::Schema Schema}
|
53
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Schema Schema} associated to this data
|
54
54
|
# store.
|
55
55
|
# @!attribute [rw] content_config
|
56
56
|
# @return [::Google::Cloud::DiscoveryEngine::V1::DataStore::ContentConfig]
|
@@ -61,6 +61,9 @@ module Google
|
|
61
61
|
# @return [::Google::Protobuf::Timestamp]
|
62
62
|
# Output only. Timestamp the
|
63
63
|
# {::Google::Cloud::DiscoveryEngine::V1::DataStore DataStore} was created at.
|
64
|
+
# @!attribute [rw] advanced_site_search_config
|
65
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AdvancedSiteSearchConfig]
|
66
|
+
# Optional. Configuration for advanced site search.
|
64
67
|
# @!attribute [r] billing_estimation
|
65
68
|
# @return [::Google::Cloud::DiscoveryEngine::V1::DataStore::BillingEstimation]
|
66
69
|
# Output only. Data size estimation for billing.
|
@@ -80,9 +83,12 @@ module Google
|
|
80
83
|
# {::Google::Cloud::DiscoveryEngine::V1::DataStore DataStore} when provisioning
|
81
84
|
# it. If unset, a default vertical specialized schema will be used.
|
82
85
|
#
|
83
|
-
# This field is only used by
|
84
|
-
#
|
85
|
-
#
|
86
|
+
# This field is only used by
|
87
|
+
# {::Google::Cloud::DiscoveryEngine::V1::DataStoreService::Client#create_data_store CreateDataStore}
|
88
|
+
# API, and will be ignored if used in other APIs. This field will be omitted
|
89
|
+
# from all API responses including
|
90
|
+
# {::Google::Cloud::DiscoveryEngine::V1::DataStoreService::Client#create_data_store CreateDataStore}
|
91
|
+
# API. To retrieve a schema of a
|
86
92
|
# {::Google::Cloud::DiscoveryEngine::V1::DataStore DataStore}, use
|
87
93
|
# {::Google::Cloud::DiscoveryEngine::V1::SchemaService::Client#get_schema SchemaService.GetSchema}
|
88
94
|
# API instead.
|
@@ -141,6 +147,18 @@ module Google
|
|
141
147
|
end
|
142
148
|
end
|
143
149
|
|
150
|
+
# Configuration data for advance site search.
|
151
|
+
# @!attribute [rw] disable_initial_index
|
152
|
+
# @return [::Boolean]
|
153
|
+
# If set true, initial indexing is disabled for the DataStore.
|
154
|
+
# @!attribute [rw] disable_automatic_refresh
|
155
|
+
# @return [::Boolean]
|
156
|
+
# If set true, automatic refresh is disabled for the DataStore.
|
157
|
+
class AdvancedSiteSearchConfig
|
158
|
+
include ::Google::Protobuf::MessageExts
|
159
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
160
|
+
end
|
161
|
+
|
144
162
|
# Config to store data store type configuration for workspace data
|
145
163
|
# @!attribute [rw] type
|
146
164
|
# @return [::Google::Cloud::DiscoveryEngine::V1::WorkspaceConfig::Type]
|
@@ -187,6 +205,9 @@ module Google
|
|
187
205
|
|
188
206
|
# Workspace Data Store contains Keep data
|
189
207
|
GOOGLE_KEEP = 7
|
208
|
+
|
209
|
+
# Workspace Data Store contains People data
|
210
|
+
GOOGLE_PEOPLE = 8
|
190
211
|
end
|
191
212
|
end
|
192
213
|
end
|
@@ -50,7 +50,7 @@ module Google
|
|
50
50
|
# Immutable. The identifier of the document.
|
51
51
|
#
|
52
52
|
# Id should conform to [RFC-1034](https://tools.ietf.org/html/rfc1034)
|
53
|
-
# standard with a length limit of
|
53
|
+
# standard with a length limit of 128 characters.
|
54
54
|
# @!attribute [rw] schema_id
|
55
55
|
# @return [::String]
|
56
56
|
# The identifier of the schema located in the same data store.
|
@@ -84,7 +84,8 @@ module Google
|
|
84
84
|
# * If document is indexed successfully, the index_time field is populated.
|
85
85
|
# * Otherwise, if document is not indexed due to errors, the error_samples
|
86
86
|
# field is populated.
|
87
|
-
# * Otherwise,
|
87
|
+
# * Otherwise, if document's index is in progress, the pending_message field
|
88
|
+
# is populated.
|
88
89
|
class Document
|
89
90
|
include ::Google::Protobuf::MessageExts
|
90
91
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -134,6 +135,10 @@ module Google
|
|
134
135
|
# @return [::Array<::Google::Rpc::Status>]
|
135
136
|
# A sample of errors encountered while indexing the document.
|
136
137
|
# If this field is populated, the document is not indexed due to errors.
|
138
|
+
# @!attribute [rw] pending_message
|
139
|
+
# @return [::String]
|
140
|
+
# Immutable. The message indicates the document index is in progress.
|
141
|
+
# If this field is populated, the document index is pending.
|
137
142
|
class IndexStatus
|
138
143
|
include ::Google::Protobuf::MessageExts
|
139
144
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|