google-cloud-discovery_engine-v1 1.0.2 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/discovery_engine/v1/completion_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/control_service/client.rb +6 -6
- data/lib/google/cloud/discovery_engine/v1/control_service/rest/client.rb +6 -6
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/client.rb +15 -12
- data/lib/google/cloud/discovery_engine/v1/conversational_search_service/rest/client.rb +15 -12
- data/lib/google/cloud/discovery_engine/v1/data_store_service/client.rb +10 -1
- data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/client.rb +10 -1
- data/lib/google/cloud/discovery_engine/v1/data_store_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/document_service/client.rb +109 -1
- data/lib/google/cloud/discovery_engine/v1/document_service/paths.rb +25 -0
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/client.rb +102 -1
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/document_service/rest/service_stub.rb +66 -0
- data/lib/google/cloud/discovery_engine/v1/engine_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/client.rb +219 -3
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/paths.rb +85 -0
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest/client.rb +126 -3
- data/lib/google/cloud/discovery_engine/v1/grounded_generation_service/rest/service_stub.rb +60 -0
- data/lib/google/cloud/discovery_engine/v1/project_service/rest/operations.rb +14 -0
- 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 +2 -1
- data/lib/google/cloud/discovery_engine/v1/recommendation_service/rest/client.rb +2 -1
- data/lib/google/cloud/discovery_engine/v1/rest.rb +1 -0
- data/lib/google/cloud/discovery_engine/v1/schema_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/search_service/client.rb +11 -4
- data/lib/google/cloud/discovery_engine/v1/search_service/rest/client.rb +11 -4
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/client.rb +571 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/credentials.rb +47 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/operations.rb +809 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/paths.rb +78 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/rest/client.rb +531 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/rest/operations.rb +1128 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/rest/service_stub.rb +188 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service/rest.rb +53 -0
- data/lib/google/cloud/discovery_engine/v1/search_tuning_service.rb +56 -0
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/client.rb +5 -1
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/client.rb +5 -1
- data/lib/google/cloud/discovery_engine/v1/site_search_engine_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/client.rb +139 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/client.rb +132 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/operations.rb +14 -0
- data/lib/google/cloud/discovery_engine/v1/user_event_service/rest/service_stub.rb +68 -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 +2 -1
- data/lib/google/cloud/discoveryengine/v1/common_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/conversational_search_service_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/custom_tuning_model_pb.rb +48 -0
- data/lib/google/cloud/discoveryengine/v1/data_store_pb.rb +4 -1
- data/lib/google/cloud/discoveryengine/v1/data_store_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/document_pb.rb +4 -1
- data/lib/google/cloud/discoveryengine/v1/document_service_pb.rb +11 -1
- data/lib/google/cloud/discoveryengine/v1/document_service_services_pb.rb +4 -0
- data/lib/google/cloud/discoveryengine/v1/engine_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_pb.rb +23 -1
- data/lib/google/cloud/discoveryengine/v1/grounded_generation_service_services_pb.rb +4 -0
- data/lib/google/cloud/discoveryengine/v1/import_config_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/purge_config_pb.rb +8 -1
- data/lib/google/cloud/discoveryengine/v1/search_service_pb.rb +5 -1
- data/lib/google/cloud/discoveryengine/v1/search_tuning_service_pb.rb +61 -0
- data/lib/google/cloud/discoveryengine/v1/search_tuning_service_services_pb.rb +47 -0
- data/lib/google/cloud/discoveryengine/v1/site_search_engine_service_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_pb.rb +1 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_service_pb.rb +2 -1
- data/lib/google/cloud/discoveryengine/v1/user_event_service_services_pb.rb +5 -0
- data/proto_docs/google/cloud/discoveryengine/v1/answer.rb +62 -7
- data/proto_docs/google/cloud/discoveryengine/v1/control.rb +6 -4
- data/proto_docs/google/cloud/discoveryengine/v1/control_service.rb +6 -6
- data/proto_docs/google/cloud/discoveryengine/v1/conversational_search_service.rb +68 -24
- data/proto_docs/google/cloud/discoveryengine/v1/custom_tuning_model.rb +99 -0
- data/proto_docs/google/cloud/discoveryengine/v1/data_store.rb +88 -0
- data/proto_docs/google/cloud/discoveryengine/v1/data_store_service.rb +10 -0
- data/proto_docs/google/cloud/discoveryengine/v1/document.rb +22 -0
- data/proto_docs/google/cloud/discoveryengine/v1/document_processing_config.rb +9 -5
- data/proto_docs/google/cloud/discoveryengine/v1/document_service.rb +120 -0
- data/proto_docs/google/cloud/discoveryengine/v1/engine.rb +5 -1
- data/proto_docs/google/cloud/discoveryengine/v1/grounded_generation_service.rb +385 -1
- data/proto_docs/google/cloud/discoveryengine/v1/import_config.rb +13 -7
- data/proto_docs/google/cloud/discoveryengine/v1/project.rb +1 -1
- data/proto_docs/google/cloud/discoveryengine/v1/purge_config.rb +115 -0
- data/proto_docs/google/cloud/discoveryengine/v1/rank_service.rb +1 -1
- data/proto_docs/google/cloud/discoveryengine/v1/recommendation_service.rb +2 -1
- data/proto_docs/google/cloud/discoveryengine/v1/search_service.rb +156 -16
- data/proto_docs/google/cloud/discoveryengine/v1/search_tuning_service.rb +172 -0
- data/proto_docs/google/cloud/discoveryengine/v1/site_search_engine_service.rb +5 -0
- data/proto_docs/google/cloud/discoveryengine/v1/user_event.rb +5 -1
- metadata +17 -3
@@ -10,11 +10,12 @@ require 'google/api/field_behavior_pb'
|
|
10
10
|
require 'google/api/httpbody_pb'
|
11
11
|
require 'google/api/resource_pb'
|
12
12
|
require 'google/cloud/discoveryengine/v1/import_config_pb'
|
13
|
+
require 'google/cloud/discoveryengine/v1/purge_config_pb'
|
13
14
|
require 'google/cloud/discoveryengine/v1/user_event_pb'
|
14
15
|
require 'google/longrunning/operations_pb'
|
15
16
|
|
16
17
|
|
17
|
-
descriptor_data = "\n8google/cloud/discoveryengine/v1/user_event_service.proto\x12\x1fgoogle.cloud.discoveryengine.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x19google/api/resource.proto\x1a\x33google/cloud/discoveryengine/v1/import_config.proto\x1a\x30google/cloud/discoveryengine/v1/user_event.proto\x1a#google/longrunning/operations.proto\"\xc7\x01\n\x15WriteUserEventRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(discoveryengine.googleapis.com/DataStore\x12H\n\nuser_event\x18\x02 \x01(\x0b\x32*.google.cloud.discoveryengine.v1.UserEventB\x03\xe0\x41\x02H\x00\x88\x01\x01\x12\x13\n\x0bwrite_async\x18\x03 \x01(\x08\x42\r\n\x0b_user_event\"\xa8\x01\n\x17\x43ollectUserEventRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(discoveryengine.googleapis.com/DataStore\x12\x17\n\nuser_event\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12\x10\n\x03uri\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x10\n\x03\x65ts\x18\x04 \x01(\x03H\x01\x88\x01\x01\x42\x06\n\x04_uriB\x06\n\x04_ets2\
|
18
|
+
descriptor_data = "\n8google/cloud/discoveryengine/v1/user_event_service.proto\x12\x1fgoogle.cloud.discoveryengine.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/httpbody.proto\x1a\x19google/api/resource.proto\x1a\x33google/cloud/discoveryengine/v1/import_config.proto\x1a\x32google/cloud/discoveryengine/v1/purge_config.proto\x1a\x30google/cloud/discoveryengine/v1/user_event.proto\x1a#google/longrunning/operations.proto\"\xc7\x01\n\x15WriteUserEventRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(discoveryengine.googleapis.com/DataStore\x12H\n\nuser_event\x18\x02 \x01(\x0b\x32*.google.cloud.discoveryengine.v1.UserEventB\x03\xe0\x41\x02H\x00\x88\x01\x01\x12\x13\n\x0bwrite_async\x18\x03 \x01(\x08\x42\r\n\x0b_user_event\"\xa8\x01\n\x17\x43ollectUserEventRequest\x12@\n\x06parent\x18\x01 \x01(\tB0\xe0\x41\x02\xfa\x41*\n(discoveryengine.googleapis.com/DataStore\x12\x17\n\nuser_event\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12\x10\n\x03uri\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x10\n\x03\x65ts\x18\x04 \x01(\x03H\x01\x88\x01\x01\x42\x06\n\x04_uriB\x06\n\x04_ets2\xb0\x0c\n\x10UserEventService\x12\xf0\x02\n\x0eWriteUserEvent\x12\x36.google.cloud.discoveryengine.v1.WriteUserEventRequest\x1a*.google.cloud.discoveryengine.v1.UserEvent\"\xf9\x01\x82\xd3\xe4\x93\x02\xf2\x01\"A/v1/{parent=projects/*/locations/*/dataStores/*}/userEvents:write:\nuser_eventZ]\"O/v1/{parent=projects/*/locations/*/collections/*/dataStores/*}/userEvents:write:\nuser_eventZB\"4/v1/{parent=projects/*/locations/*}/userEvents:write:\nuser_event\x12\xc0\x02\n\x10\x43ollectUserEvent\x12\x38.google.cloud.discoveryengine.v1.CollectUserEventRequest\x1a\x14.google.api.HttpBody\"\xdb\x01\x82\xd3\xe4\x93\x02\xd4\x01\x12\x43/v1/{parent=projects/*/locations/*/dataStores/*}/userEvents:collectZS\x12Q/v1/{parent=projects/*/locations/*/collections/*/dataStores/*}/userEvents:collectZ8\x12\x36/v1/{parent=projects/*/locations/*}/userEvents:collect\x12\x84\x03\n\x0fPurgeUserEvents\x12\x37.google.cloud.discoveryengine.v1.PurgeUserEventsRequest\x1a\x1d.google.longrunning.Operation\"\x98\x02\xca\x41r\n7google.cloud.discoveryengine.v1.PurgeUserEventsResponse\x12\x37google.cloud.discoveryengine.v1.PurgeUserEventsMetadata\x82\xd3\xe4\x93\x02\x9c\x01\"A/v1/{parent=projects/*/locations/*/dataStores/*}/userEvents:purge:\x01*ZT\"O/v1/{parent=projects/*/locations/*/collections/*/dataStores/*}/userEvents:purge:\x01*\x12\x8a\x03\n\x10ImportUserEvents\x12\x38.google.cloud.discoveryengine.v1.ImportUserEventsRequest\x1a\x1d.google.longrunning.Operation\"\x9c\x02\xca\x41t\n8google.cloud.discoveryengine.v1.ImportUserEventsResponse\x12\x38google.cloud.discoveryengine.v1.ImportUserEventsMetadata\x82\xd3\xe4\x93\x02\x9e\x01\"B/v1/{parent=projects/*/locations/*/dataStores/*}/userEvents:import:\x01*ZU\"P/v1/{parent=projects/*/locations/*/collections/*/dataStores/*}/userEvents:import:\x01*\x1aR\xca\x41\x1e\x64iscoveryengine.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\x88\x02\n#com.google.cloud.discoveryengine.v1B\x15UserEventServiceProtoP\x01ZMcloud.google.com/go/discoveryengine/apiv1/discoveryenginepb;discoveryenginepb\xa2\x02\x0f\x44ISCOVERYENGINE\xaa\x02\x1fGoogle.Cloud.DiscoveryEngine.V1\xca\x02\x1fGoogle\\Cloud\\DiscoveryEngine\\V1\xea\x02\"Google::Cloud::DiscoveryEngine::V1b\x06proto3"
|
18
19
|
|
19
20
|
pool = Google::Protobuf::DescriptorPool.generated_pool
|
20
21
|
|
@@ -41,6 +41,11 @@ module Google
|
|
41
41
|
# This method is used only by the Discovery Engine API JavaScript pixel and
|
42
42
|
# Google Tag Manager. Users should not call this method directly.
|
43
43
|
rpc :CollectUserEvent, ::Google::Cloud::DiscoveryEngine::V1::CollectUserEventRequest, ::Google::Api::HttpBody
|
44
|
+
# Deletes permanently all user events specified by the filter provided.
|
45
|
+
# Depending on the number of events specified by the filter, this operation
|
46
|
+
# could take hours or days to complete. To test a filter, use the list
|
47
|
+
# command first.
|
48
|
+
rpc :PurgeUserEvents, ::Google::Cloud::DiscoveryEngine::V1::PurgeUserEventsRequest, ::Google::Longrunning::Operation
|
44
49
|
# Bulk import of user events. Request processing might be
|
45
50
|
# synchronous. Events that already exist are skipped.
|
46
51
|
# Use this method for backfilling historical user events.
|
@@ -93,6 +93,9 @@ module Google
|
|
93
93
|
# @!attribute [rw] chunk_info
|
94
94
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo]
|
95
95
|
# Chunk information.
|
96
|
+
# @!attribute [rw] structured_document_info
|
97
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::StructuredDocumentInfo]
|
98
|
+
# Structured document information.
|
96
99
|
class Reference
|
97
100
|
include ::Google::Protobuf::MessageExts
|
98
101
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -125,6 +128,13 @@ module Google
|
|
125
128
|
# @!attribute [rw] page_identifier
|
126
129
|
# @return [::String]
|
127
130
|
# Page identifier.
|
131
|
+
# @!attribute [rw] relevance_score
|
132
|
+
# @return [::Float]
|
133
|
+
# The relevance of the chunk for a given query. Values range from 0.0
|
134
|
+
# (completely irrelevant) to 1.0 (completely relevant).
|
135
|
+
# This value is for informational purpose only. It may change for
|
136
|
+
# the same query and chunk at any time due to a model retraining or
|
137
|
+
# change in implementation.
|
128
138
|
class ChunkContent
|
129
139
|
include ::Google::Protobuf::MessageExts
|
130
140
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -140,7 +150,11 @@ module Google
|
|
140
150
|
# Chunk textual content.
|
141
151
|
# @!attribute [rw] relevance_score
|
142
152
|
# @return [::Float]
|
143
|
-
#
|
153
|
+
# The relevance of the chunk for a given query. Values range from 0.0
|
154
|
+
# (completely irrelevant) to 1.0 (completely relevant).
|
155
|
+
# This value is for informational purpose only. It may change for
|
156
|
+
# the same query and chunk at any time due to a model retraining or
|
157
|
+
# change in implementation.
|
144
158
|
# @!attribute [rw] document_metadata
|
145
159
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Answer::Reference::ChunkInfo::DocumentMetadata]
|
146
160
|
# Document metadata.
|
@@ -170,6 +184,18 @@ module Google
|
|
170
184
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
171
185
|
end
|
172
186
|
end
|
187
|
+
|
188
|
+
# Structured search information.
|
189
|
+
# @!attribute [rw] document
|
190
|
+
# @return [::String]
|
191
|
+
# Document resource name.
|
192
|
+
# @!attribute [rw] struct_data
|
193
|
+
# @return [::Google::Protobuf::Struct]
|
194
|
+
# Structured search data.
|
195
|
+
class StructuredDocumentInfo
|
196
|
+
include ::Google::Protobuf::MessageExts
|
197
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
198
|
+
end
|
173
199
|
end
|
174
200
|
|
175
201
|
# Step information.
|
@@ -239,9 +265,8 @@ module Google
|
|
239
265
|
# @return [::Google::Protobuf::Struct]
|
240
266
|
# Data representation.
|
241
267
|
# The structured JSON data for the document.
|
242
|
-
# It's populated from the struct data from the Document
|
243
|
-
#
|
244
|
-
# (code pointer: http://shortn/_Ipo6KFFGBL).
|
268
|
+
# It's populated from the struct data from the Document, or the
|
269
|
+
# Chunk in search result.
|
245
270
|
class SearchResult
|
246
271
|
include ::Google::Protobuf::MessageExts
|
247
272
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -267,7 +292,11 @@ module Google
|
|
267
292
|
# Chunk textual content.
|
268
293
|
# @!attribute [rw] relevance_score
|
269
294
|
# @return [::Float]
|
270
|
-
#
|
295
|
+
# The relevance of the chunk for a given query. Values range from
|
296
|
+
# 0.0 (completely irrelevant) to 1.0 (completely relevant).
|
297
|
+
# This value is for informational purpose only. It may change for
|
298
|
+
# the same query and chunk at any time due to a model retraining or
|
299
|
+
# change in implementation.
|
271
300
|
class ChunkInfo
|
272
301
|
include ::Google::Protobuf::MessageExts
|
273
302
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -319,8 +348,14 @@ module Google
|
|
319
348
|
# Adversarial query classification type.
|
320
349
|
ADVERSARIAL_QUERY = 1
|
321
350
|
|
322
|
-
# Non-answer-seeking query classification type.
|
351
|
+
# Non-answer-seeking query classification type, for chit chat.
|
323
352
|
NON_ANSWER_SEEKING_QUERY = 2
|
353
|
+
|
354
|
+
# Jail-breaking query classification type.
|
355
|
+
JAIL_BREAKING_QUERY = 3
|
356
|
+
|
357
|
+
# Non-answer-seeking query classification type, for no clear intent.
|
358
|
+
NON_ANSWER_SEEKING_QUERY_V2 = 4
|
324
359
|
end
|
325
360
|
end
|
326
361
|
end
|
@@ -348,7 +383,9 @@ module Google
|
|
348
383
|
# The adversarial query ignored case.
|
349
384
|
ADVERSARIAL_QUERY_IGNORED = 1
|
350
385
|
|
351
|
-
# The non-answer seeking query ignored case
|
386
|
+
# The non-answer seeking query ignored case
|
387
|
+
#
|
388
|
+
# Google skips the answer if the query is chit chat.
|
352
389
|
NON_ANSWER_SEEKING_QUERY_IGNORED = 2
|
353
390
|
|
354
391
|
# The out-of-domain query ignored case.
|
@@ -367,6 +404,24 @@ module Google
|
|
367
404
|
# Google skips the answer if there is no relevant content in the
|
368
405
|
# retrieved search results.
|
369
406
|
NO_RELEVANT_CONTENT = 5
|
407
|
+
|
408
|
+
# The jail-breaking query ignored case.
|
409
|
+
#
|
410
|
+
# For example, "Reply in the tone of a competing company's CEO".
|
411
|
+
# Google skips the answer if the query is classified as a jail-breaking
|
412
|
+
# query.
|
413
|
+
JAIL_BREAKING_QUERY_IGNORED = 6
|
414
|
+
|
415
|
+
# The customer policy violation case.
|
416
|
+
#
|
417
|
+
# Google skips the summary if there is a customer policy violation
|
418
|
+
# detected. The policy is defined by the customer.
|
419
|
+
CUSTOMER_POLICY_VIOLATION = 7
|
420
|
+
|
421
|
+
# The non-answer seeking query ignored case.
|
422
|
+
#
|
423
|
+
# Google skips the answer if the query doesn't have clear intent.
|
424
|
+
NON_ANSWER_SEEKING_QUERY_IGNORED_V2 = 8
|
370
425
|
end
|
371
426
|
end
|
372
427
|
end
|
@@ -73,8 +73,9 @@ module Google
|
|
73
73
|
end
|
74
74
|
|
75
75
|
# Defines a conditioned behavior to employ during serving.
|
76
|
-
# Must be attached to a
|
77
|
-
#
|
76
|
+
# Must be attached to a
|
77
|
+
# [ServingConfig][google.cloud.discoveryengine.v1.ServingConfig] to be
|
78
|
+
# considered at serving time. Permitted actions dependent on `SolutionType`.
|
78
79
|
# @!attribute [rw] boost_action
|
79
80
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control::BoostAction]
|
80
81
|
# Defines a boost-type control
|
@@ -100,8 +101,9 @@ module Google
|
|
100
101
|
# Otherwise an INVALID ARGUMENT error is thrown.
|
101
102
|
# @!attribute [r] associated_serving_config_ids
|
102
103
|
# @return [::Array<::String>]
|
103
|
-
# Output only. List of all
|
104
|
-
#
|
104
|
+
# Output only. List of all
|
105
|
+
# [ServingConfig][google.cloud.discoveryengine.v1.ServingConfig] IDs this
|
106
|
+
# control is attached to. May take up to 10 minutes to update after changes.
|
105
107
|
# @!attribute [rw] solution_type
|
106
108
|
# @return [::Google::Cloud::DiscoveryEngine::V1::SolutionType]
|
107
109
|
# Required. Immutable. What solution the control belongs to.
|
@@ -25,9 +25,9 @@ module Google
|
|
25
25
|
# @!attribute [rw] parent
|
26
26
|
# @return [::String]
|
27
27
|
# Required. Full resource name of parent data store. Format:
|
28
|
-
# `projects/{
|
28
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`
|
29
29
|
# or
|
30
|
-
# `projects/{
|
30
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`.
|
31
31
|
# @!attribute [rw] control
|
32
32
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Control]
|
33
33
|
# Required. The Control to create.
|
@@ -66,7 +66,7 @@ module Google
|
|
66
66
|
# @!attribute [rw] name
|
67
67
|
# @return [::String]
|
68
68
|
# Required. The resource name of the Control to delete. Format:
|
69
|
-
# `projects/{
|
69
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}`
|
70
70
|
class DeleteControlRequest
|
71
71
|
include ::Google::Protobuf::MessageExts
|
72
72
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -76,7 +76,7 @@ module Google
|
|
76
76
|
# @!attribute [rw] name
|
77
77
|
# @return [::String]
|
78
78
|
# Required. The resource name of the Control to get. Format:
|
79
|
-
# `projects/{
|
79
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}`
|
80
80
|
class GetControlRequest
|
81
81
|
include ::Google::Protobuf::MessageExts
|
82
82
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -86,9 +86,9 @@ module Google
|
|
86
86
|
# @!attribute [rw] parent
|
87
87
|
# @return [::String]
|
88
88
|
# Required. The data store resource name. Format:
|
89
|
-
# `projects/{
|
89
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}`
|
90
90
|
# or
|
91
|
-
# `projects/{
|
91
|
+
# `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`.
|
92
92
|
# @!attribute [rw] page_size
|
93
93
|
# @return [::Integer]
|
94
94
|
# Optional. Maximum number of results to return. If unspecified, defaults
|
@@ -27,9 +27,9 @@ module Google
|
|
27
27
|
# @!attribute [rw] name
|
28
28
|
# @return [::String]
|
29
29
|
# Required. The resource name of the Conversation to get. Format:
|
30
|
-
# `projects/{
|
30
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`.
|
31
31
|
# Use
|
32
|
-
# `projects/{
|
32
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/conversations/-`
|
33
33
|
# to activate auto session mode, which automatically creates a new
|
34
34
|
# conversation inside a ConverseConversation session.
|
35
35
|
# @!attribute [rw] query
|
@@ -38,7 +38,7 @@ module Google
|
|
38
38
|
# @!attribute [rw] serving_config
|
39
39
|
# @return [::String]
|
40
40
|
# The resource name of the Serving Config to use. Format:
|
41
|
-
# `projects/{
|
41
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/servingConfigs/{serving_config_id}`
|
42
42
|
# If this is not set, the default serving config will be used.
|
43
43
|
# @!attribute [rw] conversation
|
44
44
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Conversation]
|
@@ -128,7 +128,7 @@ module Google
|
|
128
128
|
# @!attribute [rw] parent
|
129
129
|
# @return [::String]
|
130
130
|
# Required. Full resource name of parent data store. Format:
|
131
|
-
# `projects/{
|
131
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}`
|
132
132
|
# @!attribute [rw] conversation
|
133
133
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Conversation]
|
134
134
|
# Required. The conversation to create.
|
@@ -159,7 +159,7 @@ module Google
|
|
159
159
|
# @!attribute [rw] name
|
160
160
|
# @return [::String]
|
161
161
|
# Required. The resource name of the Conversation to delete. Format:
|
162
|
-
# `projects/{
|
162
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`
|
163
163
|
class DeleteConversationRequest
|
164
164
|
include ::Google::Protobuf::MessageExts
|
165
165
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -169,7 +169,7 @@ module Google
|
|
169
169
|
# @!attribute [rw] name
|
170
170
|
# @return [::String]
|
171
171
|
# Required. The resource name of the Conversation to get. Format:
|
172
|
-
# `projects/{
|
172
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/conversations/{conversation_id}`
|
173
173
|
class GetConversationRequest
|
174
174
|
include ::Google::Protobuf::MessageExts
|
175
175
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -179,7 +179,7 @@ module Google
|
|
179
179
|
# @!attribute [rw] parent
|
180
180
|
# @return [::String]
|
181
181
|
# Required. The data store resource name. Format:
|
182
|
-
# `projects/{
|
182
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}`
|
183
183
|
# @!attribute [rw] page_size
|
184
184
|
# @return [::Integer]
|
185
185
|
# Maximum number of results to return. If unspecified, defaults
|
@@ -262,7 +262,11 @@ module Google
|
|
262
262
|
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::QueryUnderstandingSpec]
|
263
263
|
# Query understanding specification.
|
264
264
|
# @!attribute [rw] asynchronous_mode
|
265
|
+
# @deprecated This field is deprecated and may be removed in the next major version update.
|
265
266
|
# @return [::Boolean]
|
267
|
+
# Deprecated: This field is deprecated. Streaming Answer API will be
|
268
|
+
# supported.
|
269
|
+
#
|
266
270
|
# Asynchronous mode control.
|
267
271
|
#
|
268
272
|
# If enabled, the response will be returned with answer/session resource
|
@@ -370,6 +374,19 @@ module Google
|
|
370
374
|
# If this field is set to `false`, all search results are used regardless
|
371
375
|
# of relevance to generate answers. If set to `true` or unset, the behavior
|
372
376
|
# will be determined automatically by the service.
|
377
|
+
# @!attribute [rw] ignore_jail_breaking_query
|
378
|
+
# @return [::Boolean]
|
379
|
+
# Optional. Specifies whether to filter out jail-breaking queries. The
|
380
|
+
# default value is `false`.
|
381
|
+
#
|
382
|
+
# Google employs search-query classification to detect jail-breaking
|
383
|
+
# queries. No summary is returned if the search query is classified as a
|
384
|
+
# jail-breaking query. A user might add instructions to the query to
|
385
|
+
# change the tone, style, language, content of the answer, or ask the
|
386
|
+
# model to act as a different entity, e.g. "Reply in the tone of a
|
387
|
+
# competing company's CEO". If this field is set to `true`, we skip
|
388
|
+
# generating summaries for jail-breaking queries and return fallback
|
389
|
+
# messages instead.
|
373
390
|
class AnswerGenerationSpec
|
374
391
|
include ::Google::Protobuf::MessageExts
|
375
392
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -446,12 +463,7 @@ module Google
|
|
446
463
|
# @!attribute [rw] search_result_mode
|
447
464
|
# @return [::Google::Cloud::DiscoveryEngine::V1::SearchRequest::ContentSearchSpec::SearchResultMode]
|
448
465
|
# Specifies the search result mode. If unspecified, the
|
449
|
-
# search result mode
|
450
|
-
# [DataStore.DocumentProcessingConfig.chunking_config][]:
|
451
|
-
# * If [DataStore.DocumentProcessingConfig.chunking_config][] is
|
452
|
-
# specified,
|
453
|
-
# it defaults to `CHUNKS`.
|
454
|
-
# * Otherwise, it defaults to `DOCUMENTS`.
|
466
|
+
# search result mode defaults to `DOCUMENTS`.
|
455
467
|
# See [parse and chunk
|
456
468
|
# documents](https://cloud.google.com/generative-ai-app-builder/docs/parse-chunk-documents)
|
457
469
|
# @!attribute [rw] data_store_specs
|
@@ -496,12 +508,18 @@ module Google
|
|
496
508
|
# Title.
|
497
509
|
# @!attribute [rw] document_contexts
|
498
510
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::DocumentContext>]
|
499
|
-
# List of document contexts.
|
511
|
+
# List of document contexts. The content will be used for Answer
|
512
|
+
# Generation. This is supposed to be the main content of the document
|
513
|
+
# that can be long and comprehensive.
|
500
514
|
# @!attribute [rw] extractive_segments
|
501
515
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::ExtractiveSegment>]
|
502
516
|
# List of extractive segments.
|
503
517
|
# @!attribute [rw] extractive_answers
|
518
|
+
# @deprecated This field is deprecated and may be removed in the next major version update.
|
504
519
|
# @return [::Array<::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::UnstructuredDocumentInfo::ExtractiveAnswer>]
|
520
|
+
# Deprecated: This field is deprecated and will have no effect on
|
521
|
+
# the Answer generation.
|
522
|
+
# Please use document_contexts and extractive_segments fields.
|
505
523
|
# List of extractive answers.
|
506
524
|
class UnstructuredDocumentInfo
|
507
525
|
include ::Google::Protobuf::MessageExts
|
@@ -513,7 +531,7 @@ module Google
|
|
513
531
|
# Page identifier.
|
514
532
|
# @!attribute [rw] content
|
515
533
|
# @return [::String]
|
516
|
-
# Document content.
|
534
|
+
# Document content to be used for answer generation.
|
517
535
|
class DocumentContext
|
518
536
|
include ::Google::Protobuf::MessageExts
|
519
537
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -521,6 +539,8 @@ module Google
|
|
521
539
|
|
522
540
|
# Extractive segment.
|
523
541
|
# [Guide](https://cloud.google.com/generative-ai-app-builder/docs/snippets#extractive-segments)
|
542
|
+
# Answer generation will only use it if document_contexts is empty.
|
543
|
+
# This is supposed to be shorter snippets.
|
524
544
|
# @!attribute [rw] page_identifier
|
525
545
|
# @return [::String]
|
526
546
|
# Page identifier.
|
@@ -553,9 +573,25 @@ module Google
|
|
553
573
|
# @!attribute [rw] content
|
554
574
|
# @return [::String]
|
555
575
|
# Chunk textual content.
|
576
|
+
# @!attribute [rw] document_metadata
|
577
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::SearchSpec::SearchResultList::SearchResult::ChunkInfo::DocumentMetadata]
|
578
|
+
# Metadata of the document from the current chunk.
|
556
579
|
class ChunkInfo
|
557
580
|
include ::Google::Protobuf::MessageExts
|
558
581
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
582
|
+
|
583
|
+
# Document metadata contains the information of the document of the
|
584
|
+
# current chunk.
|
585
|
+
# @!attribute [rw] uri
|
586
|
+
# @return [::String]
|
587
|
+
# Uri of the document.
|
588
|
+
# @!attribute [rw] title
|
589
|
+
# @return [::String]
|
590
|
+
# Title of the document.
|
591
|
+
class DocumentMetadata
|
592
|
+
include ::Google::Protobuf::MessageExts
|
593
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
594
|
+
end
|
559
595
|
end
|
560
596
|
end
|
561
597
|
end
|
@@ -588,8 +624,14 @@ module Google
|
|
588
624
|
# Adversarial query classification type.
|
589
625
|
ADVERSARIAL_QUERY = 1
|
590
626
|
|
591
|
-
# Non-answer-seeking query classification type.
|
627
|
+
# Non-answer-seeking query classification type, for chit chat.
|
592
628
|
NON_ANSWER_SEEKING_QUERY = 2
|
629
|
+
|
630
|
+
# Jail-breaking query classification type.
|
631
|
+
JAIL_BREAKING_QUERY = 3
|
632
|
+
|
633
|
+
# Non-answer-seeking query classification type, for no clear intent.
|
634
|
+
NON_ANSWER_SEEKING_QUERY_V2 = 4
|
593
635
|
end
|
594
636
|
end
|
595
637
|
|
@@ -624,9 +666,11 @@ module Google
|
|
624
666
|
# @!attribute [rw] answer
|
625
667
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Answer]
|
626
668
|
# Answer resource object.
|
627
|
-
# If
|
628
|
-
#
|
629
|
-
#
|
669
|
+
# If
|
670
|
+
# {::Google::Cloud::DiscoveryEngine::V1::AnswerQueryRequest::QueryUnderstandingSpec::QueryRephraserSpec#max_rephrase_steps AnswerQueryRequest.QueryUnderstandingSpec.QueryRephraserSpec.max_rephrase_steps}
|
671
|
+
# is greater than 1, use
|
672
|
+
# {::Google::Cloud::DiscoveryEngine::V1::Answer#name Answer.name} to fetch answer
|
673
|
+
# information using
|
630
674
|
# {::Google::Cloud::DiscoveryEngine::V1::ConversationalSearchService::Client#get_answer ConversationalSearchService.GetAnswer}
|
631
675
|
# API.
|
632
676
|
# @!attribute [rw] session
|
@@ -647,7 +691,7 @@ module Google
|
|
647
691
|
# @!attribute [rw] name
|
648
692
|
# @return [::String]
|
649
693
|
# Required. The resource name of the Answer to get. Format:
|
650
|
-
# `projects/{
|
694
|
+
# `projects/{project}/locations/{location}/collections/{collection}/engines/{engine_id}/sessions/{session_id}/answers/{answer_id}`
|
651
695
|
class GetAnswerRequest
|
652
696
|
include ::Google::Protobuf::MessageExts
|
653
697
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -657,7 +701,7 @@ module Google
|
|
657
701
|
# @!attribute [rw] parent
|
658
702
|
# @return [::String]
|
659
703
|
# Required. Full resource name of parent data store. Format:
|
660
|
-
# `projects/{
|
704
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}`
|
661
705
|
# @!attribute [rw] session
|
662
706
|
# @return [::Google::Cloud::DiscoveryEngine::V1::Session]
|
663
707
|
# Required. The session to create.
|
@@ -688,7 +732,7 @@ module Google
|
|
688
732
|
# @!attribute [rw] name
|
689
733
|
# @return [::String]
|
690
734
|
# Required. The resource name of the Session to delete. Format:
|
691
|
-
# `projects/{
|
735
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/sessions/{session_id}`
|
692
736
|
class DeleteSessionRequest
|
693
737
|
include ::Google::Protobuf::MessageExts
|
694
738
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -698,7 +742,7 @@ module Google
|
|
698
742
|
# @!attribute [rw] name
|
699
743
|
# @return [::String]
|
700
744
|
# Required. The resource name of the Session to get. Format:
|
701
|
-
# `projects/{
|
745
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}/sessions/{session_id}`
|
702
746
|
class GetSessionRequest
|
703
747
|
include ::Google::Protobuf::MessageExts
|
704
748
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -708,7 +752,7 @@ module Google
|
|
708
752
|
# @!attribute [rw] parent
|
709
753
|
# @return [::String]
|
710
754
|
# Required. The data store resource name. Format:
|
711
|
-
# `projects/{
|
755
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store_id}`
|
712
756
|
# @!attribute [rw] page_size
|
713
757
|
# @return [::Integer]
|
714
758
|
# Maximum number of results to return. If unspecified, defaults
|
@@ -0,0 +1,99 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2024 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module DiscoveryEngine
|
23
|
+
module V1
|
24
|
+
# Metadata that describes a custom tuned model.
|
25
|
+
# @!attribute [rw] name
|
26
|
+
# @return [::String]
|
27
|
+
# Required. The fully qualified resource name of the model.
|
28
|
+
#
|
29
|
+
# Format:
|
30
|
+
# `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/customTuningModels/{custom_tuning_model}`.
|
31
|
+
#
|
32
|
+
# Model must be an alpha-numerical string with limit of 40 characters.
|
33
|
+
# @!attribute [rw] display_name
|
34
|
+
# @return [::String]
|
35
|
+
# The display name of the model.
|
36
|
+
# @!attribute [rw] model_version
|
37
|
+
# @return [::Integer]
|
38
|
+
# The version of the model.
|
39
|
+
# @!attribute [rw] model_state
|
40
|
+
# @return [::Google::Cloud::DiscoveryEngine::V1::CustomTuningModel::ModelState]
|
41
|
+
# The state that the model is in (e.g.`TRAINING` or `TRAINING_FAILED`).
|
42
|
+
# @!attribute [rw] create_time
|
43
|
+
# @deprecated This field is deprecated and may be removed in the next major version update.
|
44
|
+
# @return [::Google::Protobuf::Timestamp]
|
45
|
+
# Deprecated: Timestamp the Model was created at.
|
46
|
+
# @!attribute [rw] training_start_time
|
47
|
+
# @return [::Google::Protobuf::Timestamp]
|
48
|
+
# Timestamp the model training was initiated.
|
49
|
+
# @!attribute [rw] metrics
|
50
|
+
# @return [::Google::Protobuf::Map{::String => ::Float}]
|
51
|
+
# The metrics of the trained model.
|
52
|
+
# @!attribute [rw] error_message
|
53
|
+
# @return [::String]
|
54
|
+
# Currently this is only populated if the model state is
|
55
|
+
# `INPUT_VALIDATION_FAILED`.
|
56
|
+
class CustomTuningModel
|
57
|
+
include ::Google::Protobuf::MessageExts
|
58
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
59
|
+
|
60
|
+
# @!attribute [rw] key
|
61
|
+
# @return [::String]
|
62
|
+
# @!attribute [rw] value
|
63
|
+
# @return [::Float]
|
64
|
+
class MetricsEntry
|
65
|
+
include ::Google::Protobuf::MessageExts
|
66
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
67
|
+
end
|
68
|
+
|
69
|
+
# The state of the model.
|
70
|
+
module ModelState
|
71
|
+
# Default value.
|
72
|
+
MODEL_STATE_UNSPECIFIED = 0
|
73
|
+
|
74
|
+
# The model is in a paused training state.
|
75
|
+
TRAINING_PAUSED = 1
|
76
|
+
|
77
|
+
# The model is currently training.
|
78
|
+
TRAINING = 2
|
79
|
+
|
80
|
+
# The model has successfully completed training.
|
81
|
+
TRAINING_COMPLETE = 3
|
82
|
+
|
83
|
+
# The model is ready for serving.
|
84
|
+
READY_FOR_SERVING = 4
|
85
|
+
|
86
|
+
# The model training failed.
|
87
|
+
TRAINING_FAILED = 5
|
88
|
+
|
89
|
+
# The model training finished successfully but metrics did not improve.
|
90
|
+
NO_IMPROVEMENT = 6
|
91
|
+
|
92
|
+
# Input data validation failed. Model training didn't start.
|
93
|
+
INPUT_VALIDATION_FAILED = 7
|
94
|
+
end
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|
99
|
+
end
|