google-cloud-discovery_engine-v1beta 0.13.0 → 0.14.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +0 -1
- data/lib/google/cloud/discovery_engine/v1beta/completion_service/client.rb +219 -0
- data/lib/google/cloud/discovery_engine/v1beta/completion_service/rest/client.rb +205 -0
- data/lib/google/cloud/discovery_engine/v1beta/completion_service/rest/service_stub.rb +136 -0
- data/lib/google/cloud/discovery_engine/v1beta/conversational_search_service/client.rb +19 -1
- data/lib/google/cloud/discovery_engine/v1beta/conversational_search_service/rest/client.rb +19 -1
- data/lib/google/cloud/discovery_engine/v1beta/data_store_service/client.rb +10 -1
- data/lib/google/cloud/discovery_engine/v1beta/data_store_service/rest/client.rb +10 -1
- data/lib/google/cloud/discovery_engine/v1beta/document_service/client.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1beta/document_service/rest/client.rb +3 -1
- data/lib/google/cloud/discovery_engine/v1beta/evaluation_service/paths.rb +68 -0
- data/lib/google/cloud/discovery_engine/v1beta/search_service/client.rb +50 -1
- data/lib/google/cloud/discovery_engine/v1beta/search_service/paths.rb +68 -0
- data/lib/google/cloud/discovery_engine/v1beta/search_service/rest/client.rb +50 -1
- data/lib/google/cloud/discovery_engine/v1beta/user_event_service/client.rb +139 -0
- data/lib/google/cloud/discovery_engine/v1beta/user_event_service/rest/client.rb +132 -0
- data/lib/google/cloud/discovery_engine/v1beta/user_event_service/rest/service_stub.rb +75 -0
- data/lib/google/cloud/discovery_engine/v1beta/version.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/answer_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/completion_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1beta/completion_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/completion_service_services_pb.rb +8 -0
- data/lib/google/cloud/discoveryengine/v1beta/conversational_search_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/custom_tuning_model_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/data_store_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1beta/data_store_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1beta/import_config_pb.rb +6 -1
- data/lib/google/cloud/discoveryengine/v1beta/purge_config_pb.rb +7 -1
- data/lib/google/cloud/discoveryengine/v1beta/search_service_pb.rb +16 -1
- data/lib/google/cloud/discoveryengine/v1beta/user_event_service_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1beta/user_event_service_services_pb.rb +5 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/answer.rb +14 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/completion.rb +31 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/conversational_search_service.rb +28 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/custom_tuning_model.rb +16 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/data_store.rb +25 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/data_store_service.rb +10 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/import_config.rb +114 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/purge_config.rb +119 -0
- data/proto_docs/google/cloud/discoveryengine/v1beta/search_service.rb +332 -0
- metadata +2 -2
@@ -21,6 +21,83 @@ module Google
|
|
21
21
|
module Cloud
|
22
22
|
module DiscoveryEngine
|
23
23
|
module V1beta
|
24
|
+
# Request message for PurgeUserEvents method.
|
25
|
+
# @!attribute [rw] parent
|
26
|
+
# @return [::String]
|
27
|
+
# Required. The resource name of the catalog under which the events are
|
28
|
+
# created. The format is
|
29
|
+
# `projects/${projectId}/locations/global/collections/{$collectionId}/dataStores/${dataStoreId}`
|
30
|
+
# @!attribute [rw] filter
|
31
|
+
# @return [::String]
|
32
|
+
# Required. The filter string to specify the events to be deleted with a
|
33
|
+
# length limit of 5,000 characters. The eligible fields for filtering are:
|
34
|
+
#
|
35
|
+
# * `eventType`: Double quoted
|
36
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::UserEvent#event_type UserEvent.event_type}
|
37
|
+
# string.
|
38
|
+
# * `eventTime`: in ISO 8601 "zulu" format.
|
39
|
+
# * `userPseudoId`: Double quoted string. Specifying this will delete all
|
40
|
+
# events associated with a visitor.
|
41
|
+
# * `userId`: Double quoted string. Specifying this will delete all events
|
42
|
+
# associated with a user.
|
43
|
+
#
|
44
|
+
# Examples:
|
45
|
+
#
|
46
|
+
# * Deleting all events in a time range:
|
47
|
+
# `eventTime > "2012-04-23T18:25:43.511Z"
|
48
|
+
# eventTime < "2012-04-23T18:30:43.511Z"`
|
49
|
+
# * Deleting specific eventType:
|
50
|
+
# `eventType = "search"`
|
51
|
+
# * Deleting all events for a specific visitor:
|
52
|
+
# `userPseudoId = "visitor1024"`
|
53
|
+
# * Deleting all events inside a DataStore:
|
54
|
+
# `*`
|
55
|
+
#
|
56
|
+
# The filtering fields are assumed to have an implicit AND.
|
57
|
+
# @!attribute [rw] force
|
58
|
+
# @return [::Boolean]
|
59
|
+
# The `force` field is currently not supported. Purge user event requests
|
60
|
+
# will permanently delete all purgeable events. Once the development is
|
61
|
+
# complete:
|
62
|
+
# If `force` is set to false, the method will return the expected
|
63
|
+
# purge count without deleting any user events. This field will default to
|
64
|
+
# false if not included in the request.
|
65
|
+
class PurgeUserEventsRequest
|
66
|
+
include ::Google::Protobuf::MessageExts
|
67
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
68
|
+
end
|
69
|
+
|
70
|
+
# Response of the PurgeUserEventsRequest. If the long running operation is
|
71
|
+
# successfully done, then this message is returned by the
|
72
|
+
# google.longrunning.Operations.response field.
|
73
|
+
# @!attribute [rw] purge_count
|
74
|
+
# @return [::Integer]
|
75
|
+
# The total count of events purged as a result of the operation.
|
76
|
+
class PurgeUserEventsResponse
|
77
|
+
include ::Google::Protobuf::MessageExts
|
78
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
79
|
+
end
|
80
|
+
|
81
|
+
# Metadata related to the progress of the PurgeUserEvents operation.
|
82
|
+
# This will be returned by the google.longrunning.Operation.metadata field.
|
83
|
+
# @!attribute [rw] create_time
|
84
|
+
# @return [::Google::Protobuf::Timestamp]
|
85
|
+
# Operation create time.
|
86
|
+
# @!attribute [rw] update_time
|
87
|
+
# @return [::Google::Protobuf::Timestamp]
|
88
|
+
# Operation last update time. If the operation is done, this is also the
|
89
|
+
# finish time.
|
90
|
+
# @!attribute [rw] success_count
|
91
|
+
# @return [::Integer]
|
92
|
+
# Count of entries that were deleted successfully.
|
93
|
+
# @!attribute [rw] failure_count
|
94
|
+
# @return [::Integer]
|
95
|
+
# Count of entries that encountered errors while processing.
|
96
|
+
class PurgeUserEventsMetadata
|
97
|
+
include ::Google::Protobuf::MessageExts
|
98
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
99
|
+
end
|
100
|
+
|
24
101
|
# Request message for
|
25
102
|
# {::Google::Cloud::DiscoveryEngine::V1beta::DocumentService::Client#purge_documents DocumentService.PurgeDocuments}
|
26
103
|
# method.
|
@@ -122,6 +199,48 @@ module Google
|
|
122
199
|
include ::Google::Protobuf::MessageExts
|
123
200
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
124
201
|
end
|
202
|
+
|
203
|
+
# Request message for
|
204
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::CompletionService::Client#purge_completion_suggestions CompletionService.PurgeCompletionSuggestions}
|
205
|
+
# method.
|
206
|
+
# @!attribute [rw] parent
|
207
|
+
# @return [::String]
|
208
|
+
# Required. The parent data store resource name for which to purge completion
|
209
|
+
# suggestions. Follows pattern
|
210
|
+
# projects/*/locations/*/collections/*/dataStores/*.
|
211
|
+
class PurgeCompletionSuggestionsRequest
|
212
|
+
include ::Google::Protobuf::MessageExts
|
213
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
214
|
+
end
|
215
|
+
|
216
|
+
# Response message for
|
217
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::CompletionService::Client#purge_completion_suggestions CompletionService.PurgeCompletionSuggestions}
|
218
|
+
# method.
|
219
|
+
# @!attribute [rw] purge_succeeded
|
220
|
+
# @return [::Boolean]
|
221
|
+
# Whether the completion suggestions were successfully purged.
|
222
|
+
# @!attribute [rw] error_samples
|
223
|
+
# @return [::Array<::Google::Rpc::Status>]
|
224
|
+
# A sample of errors encountered while processing the request.
|
225
|
+
class PurgeCompletionSuggestionsResponse
|
226
|
+
include ::Google::Protobuf::MessageExts
|
227
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
228
|
+
end
|
229
|
+
|
230
|
+
# Metadata related to the progress of the PurgeCompletionSuggestions
|
231
|
+
# operation. This is returned by the google.longrunning.Operation.metadata
|
232
|
+
# field.
|
233
|
+
# @!attribute [rw] create_time
|
234
|
+
# @return [::Google::Protobuf::Timestamp]
|
235
|
+
# Operation create time.
|
236
|
+
# @!attribute [rw] update_time
|
237
|
+
# @return [::Google::Protobuf::Timestamp]
|
238
|
+
# Operation last update time. If the operation is done, this is also the
|
239
|
+
# finish time.
|
240
|
+
class PurgeCompletionSuggestionsMetadata
|
241
|
+
include ::Google::Protobuf::MessageExts
|
242
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
243
|
+
end
|
125
244
|
end
|
126
245
|
end
|
127
246
|
end
|
@@ -130,6 +130,19 @@ module Google
|
|
130
130
|
# Highly recommended for analytics.
|
131
131
|
# {::Google::Cloud::DiscoveryEngine::V1beta::UserInfo#user_agent UserInfo.user_agent}
|
132
132
|
# is used to deduce `device_type` for analytics.
|
133
|
+
# @!attribute [rw] language_code
|
134
|
+
# @return [::String]
|
135
|
+
# The BCP-47 language code, such as "en-US" or "sr-Latn". For more
|
136
|
+
# information, see [Standard
|
137
|
+
# fields](https://cloud.google.com/apis/design/standard_fields). This field
|
138
|
+
# helps to better interpret the query. If a value isn't specified, the query
|
139
|
+
# language code is automatically detected, which may not be accurate.
|
140
|
+
# @!attribute [rw] region_code
|
141
|
+
# @return [::String]
|
142
|
+
# The Unicode country/region code (CLDR) of a location, such as "US" and
|
143
|
+
# "419". For more information, see [Standard
|
144
|
+
# fields](https://cloud.google.com/apis/design/standard_fields). If set,
|
145
|
+
# then results will be boosted based on the region_code provided.
|
133
146
|
# @!attribute [rw] facet_specs
|
134
147
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::FacetSpec>]
|
135
148
|
# Facet specifications for faceted search. If empty, no facets are returned.
|
@@ -248,6 +261,48 @@ module Google
|
|
248
261
|
# See [Google Cloud
|
249
262
|
# Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements)
|
250
263
|
# for more details.
|
264
|
+
# @!attribute [rw] natural_language_query_understanding_spec
|
265
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::NaturalLanguageQueryUnderstandingSpec]
|
266
|
+
# If `naturalLanguageQueryUnderstandingSpec` is not specified, no additional
|
267
|
+
# natural language query understanding will be done.
|
268
|
+
# @!attribute [rw] search_as_you_type_spec
|
269
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::SearchAsYouTypeSpec]
|
270
|
+
# Search as you type configuration. Only supported for the
|
271
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::IndustryVertical::MEDIA IndustryVertical.MEDIA}
|
272
|
+
# vertical.
|
273
|
+
# @!attribute [rw] session
|
274
|
+
# @return [::String]
|
275
|
+
# The session resource name. Optional.
|
276
|
+
#
|
277
|
+
# Session allows users to do multi-turn /search API calls or coordination
|
278
|
+
# between /search API calls and /answer API calls.
|
279
|
+
#
|
280
|
+
# Example #1 (multi-turn /search API calls):
|
281
|
+
# 1. Call /search API with the auto-session mode (see below).
|
282
|
+
# 2. Call /search API with the session ID generated in the first call.
|
283
|
+
# Here, the previous search query gets considered in query
|
284
|
+
# standing. I.e., if the first query is "How did Alphabet do in 2022?"
|
285
|
+
# and the current query is "How about 2023?", the current query will
|
286
|
+
# be interpreted as "How did Alphabet do in 2023?".
|
287
|
+
#
|
288
|
+
# Example #2 (coordination between /search API calls and /answer API calls):
|
289
|
+
# 1. Call /search API with the auto-session mode (see below).
|
290
|
+
# 2. Call /answer API with the session ID generated in the first call.
|
291
|
+
# Here, the answer generation happens in the context of the search
|
292
|
+
# results from the first search call.
|
293
|
+
#
|
294
|
+
# Auto-session mode: when `projects/.../sessions/-` is used, a new session
|
295
|
+
# gets automatically created. Otherwise, users can use the create-session API
|
296
|
+
# to create a session manually.
|
297
|
+
#
|
298
|
+
# Multi-turn Search feature is currently at private GA stage. Please use
|
299
|
+
# v1alpha or v1beta version instead before we launch this feature to public
|
300
|
+
# GA. Or ask for allowlisting through Google Support team.
|
301
|
+
# @!attribute [rw] session_spec
|
302
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::SessionSpec]
|
303
|
+
# Session specification.
|
304
|
+
#
|
305
|
+
# Can be used only when `session` is set.
|
251
306
|
class SearchRequest
|
252
307
|
include ::Google::Protobuf::MessageExts
|
253
308
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -888,6 +943,107 @@ module Google
|
|
888
943
|
end
|
889
944
|
end
|
890
945
|
|
946
|
+
# Specification to enable natural language understanding capabilities for
|
947
|
+
# search requests.
|
948
|
+
# @!attribute [rw] filter_extraction_condition
|
949
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::NaturalLanguageQueryUnderstandingSpec::FilterExtractionCondition]
|
950
|
+
# The condition under which filter extraction should occur.
|
951
|
+
# Default to [Condition.DISABLED][].
|
952
|
+
# @!attribute [rw] geo_search_query_detection_field_names
|
953
|
+
# @return [::Array<::String>]
|
954
|
+
# Field names used for location-based filtering, where geolocation filters
|
955
|
+
# are detected in natural language search queries.
|
956
|
+
# Only valid when the FilterExtractionCondition is set to `ENABLED`.
|
957
|
+
#
|
958
|
+
# If this field is set, it overrides the field names set in
|
959
|
+
# [ServingConfig.geo_search_query_detection_field_names][google.cloud.discoveryengine.v1beta.ServingConfig.geo_search_query_detection_field_names].
|
960
|
+
class NaturalLanguageQueryUnderstandingSpec
|
961
|
+
include ::Google::Protobuf::MessageExts
|
962
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
963
|
+
|
964
|
+
# Enum describing under which condition filter extraction should occur.
|
965
|
+
module FilterExtractionCondition
|
966
|
+
# Server behavior defaults to [Condition.DISABLED][].
|
967
|
+
CONDITION_UNSPECIFIED = 0
|
968
|
+
|
969
|
+
# Disables NL filter extraction.
|
970
|
+
DISABLED = 1
|
971
|
+
|
972
|
+
# Enables NL filter extraction.
|
973
|
+
ENABLED = 2
|
974
|
+
end
|
975
|
+
end
|
976
|
+
|
977
|
+
# Specification for search as you type in search requests.
|
978
|
+
# @!attribute [rw] condition
|
979
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::SearchAsYouTypeSpec::Condition]
|
980
|
+
# The condition under which search as you type should occur.
|
981
|
+
# Default to
|
982
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::SearchAsYouTypeSpec::Condition::DISABLED Condition.DISABLED}.
|
983
|
+
class SearchAsYouTypeSpec
|
984
|
+
include ::Google::Protobuf::MessageExts
|
985
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
986
|
+
|
987
|
+
# Enum describing under which condition search as you type should occur.
|
988
|
+
module Condition
|
989
|
+
# Server behavior defaults to
|
990
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::SearchAsYouTypeSpec::Condition::DISABLED Condition.DISABLED}.
|
991
|
+
CONDITION_UNSPECIFIED = 0
|
992
|
+
|
993
|
+
# Disables Search As You Type.
|
994
|
+
DISABLED = 1
|
995
|
+
|
996
|
+
# Enables Search As You Type.
|
997
|
+
ENABLED = 2
|
998
|
+
end
|
999
|
+
end
|
1000
|
+
|
1001
|
+
# Session specification.
|
1002
|
+
#
|
1003
|
+
# Multi-turn Search feature is currently at private GA stage. Please use
|
1004
|
+
# v1alpha or v1beta version instead before we launch this feature to public
|
1005
|
+
# GA. Or ask for allowlisting through Google Support team.
|
1006
|
+
# @!attribute [rw] query_id
|
1007
|
+
# @return [::String]
|
1008
|
+
# If set, the search result gets stored to the "turn" specified by this
|
1009
|
+
# query ID.
|
1010
|
+
#
|
1011
|
+
# Example: Let's say the session looks like this:
|
1012
|
+
# session {
|
1013
|
+
# name: ".../sessions/xxx"
|
1014
|
+
# turns {
|
1015
|
+
# query { text: "What is foo?" query_id: ".../questions/yyy" }
|
1016
|
+
# answer: "Foo is ..."
|
1017
|
+
# }
|
1018
|
+
# turns {
|
1019
|
+
# query { text: "How about bar then?" query_id: ".../questions/zzz" }
|
1020
|
+
# }
|
1021
|
+
# }
|
1022
|
+
#
|
1023
|
+
# The user can call /search API with a request like this:
|
1024
|
+
#
|
1025
|
+
# session: ".../sessions/xxx"
|
1026
|
+
# session_spec { query_id: ".../questions/zzz" }
|
1027
|
+
#
|
1028
|
+
# Then, the API stores the search result, associated with the last turn.
|
1029
|
+
# The stored search result can be used by a subsequent /answer API call
|
1030
|
+
# (with the session ID and the query ID specified). Also, it is possible
|
1031
|
+
# to call /search and /answer in parallel with the same session ID & query
|
1032
|
+
# ID.
|
1033
|
+
# @!attribute [rw] search_result_persistence_count
|
1034
|
+
# @return [::Integer]
|
1035
|
+
# The number of top search results to persist. The persisted search results
|
1036
|
+
# can be used for the subsequent /answer api call.
|
1037
|
+
#
|
1038
|
+
# This field is simliar to the `summary_result_count` field in
|
1039
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest::ContentSearchSpec::SummarySpec#summary_result_count SearchRequest.ContentSearchSpec.SummarySpec.summary_result_count}.
|
1040
|
+
#
|
1041
|
+
# At most 10 results for documents mode, or 50 for chunks mode.
|
1042
|
+
class SessionSpec
|
1043
|
+
include ::Google::Protobuf::MessageExts
|
1044
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1045
|
+
end
|
1046
|
+
|
891
1047
|
# @!attribute [rw] key
|
892
1048
|
# @return [::String]
|
893
1049
|
# @!attribute [rw] value
|
@@ -966,6 +1122,16 @@ module Google
|
|
966
1122
|
# @!attribute [rw] query_expansion_info
|
967
1123
|
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::QueryExpansionInfo]
|
968
1124
|
# Query expansion information for the returned results.
|
1125
|
+
# @!attribute [rw] natural_language_query_understanding_info
|
1126
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo]
|
1127
|
+
# Natural language query understanding information for the returned results.
|
1128
|
+
# @!attribute [rw] session_info
|
1129
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::SessionInfo]
|
1130
|
+
# Session information.
|
1131
|
+
#
|
1132
|
+
# Only set if
|
1133
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest#session SearchRequest.session}
|
1134
|
+
# is provided. See its description for more details.
|
969
1135
|
class SearchResponse
|
970
1136
|
include ::Google::Protobuf::MessageExts
|
971
1137
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -1213,6 +1379,12 @@ module Google
|
|
1213
1379
|
#
|
1214
1380
|
# Google skips the summary if the LLM addon is not enabled.
|
1215
1381
|
LLM_ADDON_NOT_ENABLED = 5
|
1382
|
+
|
1383
|
+
# The no relevant content case.
|
1384
|
+
#
|
1385
|
+
# Google skips the summary if there is no relevant content in the
|
1386
|
+
# retrieved search results.
|
1387
|
+
NO_RELEVANT_CONTENT = 6
|
1216
1388
|
end
|
1217
1389
|
end
|
1218
1390
|
|
@@ -1244,6 +1416,166 @@ module Google
|
|
1244
1416
|
include ::Google::Protobuf::MessageExts
|
1245
1417
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1246
1418
|
end
|
1419
|
+
|
1420
|
+
# Information describing what natural language understanding was
|
1421
|
+
# done on the input query.
|
1422
|
+
# @!attribute [rw] extracted_filters
|
1423
|
+
# @return [::String]
|
1424
|
+
# The filters that were extracted from the input query.
|
1425
|
+
# @!attribute [rw] rewritten_query
|
1426
|
+
# @return [::String]
|
1427
|
+
# Rewritten input query minus the extracted filters.
|
1428
|
+
# @!attribute [rw] structured_extracted_filter
|
1429
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter]
|
1430
|
+
# The filters that were extracted from the input query represented in a
|
1431
|
+
# structured form.
|
1432
|
+
class NaturalLanguageQueryUnderstandingInfo
|
1433
|
+
include ::Google::Protobuf::MessageExts
|
1434
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1435
|
+
|
1436
|
+
# The filters that were extracted from the input query represented in a
|
1437
|
+
# structured form.
|
1438
|
+
# @!attribute [rw] expression
|
1439
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression]
|
1440
|
+
# The expression denoting the filter that was extracted from the input
|
1441
|
+
# query in a structured form. It can be a simple expression denoting a
|
1442
|
+
# single string, numerical or geolocation constraint or a compound
|
1443
|
+
# expression which is a combination of multiple expressions connected
|
1444
|
+
# using logical (OR and AND) operators.
|
1445
|
+
class StructuredExtractedFilter
|
1446
|
+
include ::Google::Protobuf::MessageExts
|
1447
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1448
|
+
|
1449
|
+
# Constraint expression of a string field.
|
1450
|
+
# @!attribute [rw] field_name
|
1451
|
+
# @return [::String]
|
1452
|
+
# Name of the string field as defined in the schema.
|
1453
|
+
# @!attribute [rw] values
|
1454
|
+
# @return [::Array<::String>]
|
1455
|
+
# Values of the string field. The record will only be returned if the
|
1456
|
+
# field value matches one of the values specified here.
|
1457
|
+
class StringConstraint
|
1458
|
+
include ::Google::Protobuf::MessageExts
|
1459
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1460
|
+
end
|
1461
|
+
|
1462
|
+
# Constraint expression of a number field. Example: price < 100.
|
1463
|
+
# @!attribute [rw] field_name
|
1464
|
+
# @return [::String]
|
1465
|
+
# Name of the numerical field as defined in the schema.
|
1466
|
+
# @!attribute [rw] comparison
|
1467
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint::Comparison]
|
1468
|
+
# The comparison operation performed between the field value and the
|
1469
|
+
# value specified in the constraint.
|
1470
|
+
# @!attribute [rw] value
|
1471
|
+
# @return [::Float]
|
1472
|
+
# The value specified in the numerical constraint.
|
1473
|
+
class NumberConstraint
|
1474
|
+
include ::Google::Protobuf::MessageExts
|
1475
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1476
|
+
|
1477
|
+
# The comparison operation that was performed.
|
1478
|
+
module Comparison
|
1479
|
+
# Undefined comparison operator.
|
1480
|
+
COMPARISON_UNSPECIFIED = 0
|
1481
|
+
|
1482
|
+
# Denotes equality `=` operator.
|
1483
|
+
EQUALS = 1
|
1484
|
+
|
1485
|
+
# Denotes less than or equal to `<=` operator.
|
1486
|
+
LESS_THAN_EQUALS = 2
|
1487
|
+
|
1488
|
+
# Denotes less than `<` operator.
|
1489
|
+
LESS_THAN = 3
|
1490
|
+
|
1491
|
+
# Denotes greater than or equal to `>=` operator.
|
1492
|
+
GREATER_THAN_EQUALS = 4
|
1493
|
+
|
1494
|
+
# Denotes greater than `>` operator.
|
1495
|
+
GREATER_THAN = 5
|
1496
|
+
end
|
1497
|
+
end
|
1498
|
+
|
1499
|
+
# Constraint of a geolocation field.
|
1500
|
+
# Name of the geolocation field as defined in the schema.
|
1501
|
+
# @!attribute [rw] field_name
|
1502
|
+
# @return [::String]
|
1503
|
+
# The name of the geolocation field as defined in the schema.
|
1504
|
+
# @!attribute [rw] address
|
1505
|
+
# @return [::String]
|
1506
|
+
# The reference address that was inferred from the input query. The
|
1507
|
+
# proximity of the reference address to the geolocation field will be
|
1508
|
+
# used to filter the results.
|
1509
|
+
# @!attribute [rw] radius_in_meters
|
1510
|
+
# @return [::Float]
|
1511
|
+
# The radius in meters around the address. The record is returned if
|
1512
|
+
# the location of the geolocation field is within the radius.
|
1513
|
+
class GeolocationConstraint
|
1514
|
+
include ::Google::Protobuf::MessageExts
|
1515
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1516
|
+
end
|
1517
|
+
|
1518
|
+
# Logical `And` operator.
|
1519
|
+
# @!attribute [rw] expressions
|
1520
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>]
|
1521
|
+
# The expressions that were ANDed together.
|
1522
|
+
class AndExpression
|
1523
|
+
include ::Google::Protobuf::MessageExts
|
1524
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1525
|
+
end
|
1526
|
+
|
1527
|
+
# Logical `Or` operator.
|
1528
|
+
# @!attribute [rw] expressions
|
1529
|
+
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::Expression>]
|
1530
|
+
# The expressions that were ORed together.
|
1531
|
+
class OrExpression
|
1532
|
+
include ::Google::Protobuf::MessageExts
|
1533
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1534
|
+
end
|
1535
|
+
|
1536
|
+
# The expression denoting the filter that was extracted from the input
|
1537
|
+
# query.
|
1538
|
+
# @!attribute [rw] string_constraint
|
1539
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::StringConstraint]
|
1540
|
+
# String constraint expression.
|
1541
|
+
# @!attribute [rw] number_constraint
|
1542
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::NumberConstraint]
|
1543
|
+
# Numerical constraint expression.
|
1544
|
+
# @!attribute [rw] geolocation_constraint
|
1545
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::GeolocationConstraint]
|
1546
|
+
# Geolocation constraint expression.
|
1547
|
+
# @!attribute [rw] and_expr
|
1548
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::AndExpression]
|
1549
|
+
# Logical "And" compound operator connecting multiple expressions.
|
1550
|
+
# @!attribute [rw] or_expr
|
1551
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::NaturalLanguageQueryUnderstandingInfo::StructuredExtractedFilter::OrExpression]
|
1552
|
+
# Logical "Or" compound operator connecting multiple expressions.
|
1553
|
+
class Expression
|
1554
|
+
include ::Google::Protobuf::MessageExts
|
1555
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1556
|
+
end
|
1557
|
+
end
|
1558
|
+
end
|
1559
|
+
|
1560
|
+
# Information about the session.
|
1561
|
+
# @!attribute [rw] name
|
1562
|
+
# @return [::String]
|
1563
|
+
# Name of the session.
|
1564
|
+
# If the auto-session mode is used (when
|
1565
|
+
# {::Google::Cloud::DiscoveryEngine::V1beta::SearchRequest#session SearchRequest.session}
|
1566
|
+
# ends with "-"), this field holds the newly generated session name.
|
1567
|
+
# @!attribute [rw] query_id
|
1568
|
+
# @return [::String]
|
1569
|
+
# Query ID that corresponds to this search API call.
|
1570
|
+
# One session can have multiple turns, each with a unique query ID.
|
1571
|
+
#
|
1572
|
+
# By specifying the session name and this query ID in the Answer API call,
|
1573
|
+
# the answer generation happens in the context of the search results from
|
1574
|
+
# this search call.
|
1575
|
+
class SessionInfo
|
1576
|
+
include ::Google::Protobuf::MessageExts
|
1577
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
1578
|
+
end
|
1247
1579
|
end
|
1248
1580
|
end
|
1249
1581
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-discovery_engine-v1beta
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.14.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-08-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gapic-common
|