google-cloud-retail-v2 0.6.3 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.yardopts +1 -1
- data/AUTHENTICATION.md +7 -25
- data/README.md +6 -1
- data/lib/google/cloud/retail/v2/catalog_pb.rb +2 -4
- data/lib/google/cloud/retail/v2/catalog_service/client.rb +9 -9
- data/lib/google/cloud/retail/v2/catalog_service_pb.rb +3 -1
- data/lib/google/cloud/retail/v2/catalog_service_services_pb.rb +0 -8
- data/lib/google/cloud/retail/v2/common_pb.rb +8 -5
- data/lib/google/cloud/retail/v2/completion_service/client.rb +21 -21
- data/lib/google/cloud/retail/v2/completion_service.rb +1 -2
- data/lib/google/cloud/retail/v2/completion_service_pb.rb +2 -1
- data/lib/google/cloud/retail/v2/completion_service_services_pb.rb +7 -7
- data/lib/google/cloud/retail/v2/import_config_pb.rb +2 -2
- data/lib/google/cloud/retail/v2/prediction_service/client.rb +17 -4
- data/lib/google/cloud/retail/v2/prediction_service_pb.rb +2 -1
- data/lib/google/cloud/retail/v2/product_pb.rb +3 -2
- data/lib/google/cloud/retail/v2/product_service/client.rb +338 -23
- data/lib/google/cloud/retail/v2/product_service_pb.rb +29 -2
- data/lib/google/cloud/retail/v2/product_service_services_pb.rb +47 -9
- data/lib/google/cloud/retail/v2/promotion_pb.rb +22 -0
- data/lib/google/cloud/retail/v2/purge_config_pb.rb +3 -2
- data/lib/google/cloud/retail/v2/search_service/client.rb +56 -19
- data/lib/google/cloud/retail/v2/search_service.rb +1 -2
- data/lib/google/cloud/retail/v2/search_service_pb.rb +28 -3
- data/lib/google/cloud/retail/v2/search_service_services_pb.rb +2 -4
- data/lib/google/cloud/retail/v2/user_event_pb.rb +2 -2
- data/lib/google/cloud/retail/v2/user_event_service/client.rb +5 -3
- data/lib/google/cloud/retail/v2/user_event_service_pb.rb +3 -1
- data/lib/google/cloud/retail/v2/user_event_service_services_pb.rb +4 -3
- data/lib/google/cloud/retail/v2/version.rb +1 -1
- data/lib/google/cloud/retail/v2.rb +2 -0
- data/proto_docs/google/api/resource.rb +10 -71
- data/proto_docs/google/cloud/retail/v2/catalog.rb +8 -8
- data/proto_docs/google/cloud/retail/v2/catalog_service.rb +9 -0
- data/proto_docs/google/cloud/retail/v2/common.rb +100 -25
- data/proto_docs/google/cloud/retail/v2/completion_service.rb +28 -18
- data/proto_docs/google/cloud/retail/v2/import_config.rb +38 -23
- data/proto_docs/google/cloud/retail/v2/prediction_service.rb +19 -6
- data/proto_docs/google/cloud/retail/v2/product.rb +50 -41
- data/proto_docs/google/cloud/retail/v2/product_service.rb +154 -6
- data/proto_docs/google/cloud/retail/v2/promotion.rb +43 -0
- data/proto_docs/google/cloud/retail/v2/search_service.rb +162 -28
- data/proto_docs/google/cloud/retail/v2/user_event.rb +30 -14
- data/proto_docs/google/protobuf/any.rb +3 -3
- data/proto_docs/google/protobuf/struct.rb +2 -2
- metadata +5 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '09eebe56def80aca474541e0f90b49b98428f7530cd3cf00f76ed6d069d0d2e3'
|
4
|
+
data.tar.gz: cb93509ec2c2f405c2dd69bf015f53dfa7daf9fa685190e4f6b64ce174371ad5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: abc56ec5460f8cf74fde99d87bc6d44474a1f72fed49fb9dde8c414e2e6ac58f97061b29ca5f017af432fd3751ef160853048496689d4575146eae29fb3d4164
|
7
|
+
data.tar.gz: '08b8bf20cd8fc3c3f15a13b2b21a6fecb391d41e8697a17ba43e572e546733d9571d843be5724bd05d4e302788629f9d6a5f9562d1d0498d7f89711d0ff036a6'
|
data/.yardopts
CHANGED
data/AUTHENTICATION.md
CHANGED
@@ -120,15 +120,6 @@ To configure your system for this, simply:
|
|
120
120
|
**NOTE:** This is _not_ recommended for running in production. The Cloud SDK
|
121
121
|
*should* only be used during development.
|
122
122
|
|
123
|
-
[gce-how-to]: https://cloud.google.com/compute/docs/authentication#using
|
124
|
-
[dev-console]: https://console.cloud.google.com/project
|
125
|
-
|
126
|
-
[enable-apis]: https://raw.githubusercontent.com/GoogleCloudPlatform/gcloud-common/master/authentication/enable-apis.png
|
127
|
-
|
128
|
-
[create-new-service-account]: https://raw.githubusercontent.com/GoogleCloudPlatform/gcloud-common/master/authentication/create-new-service-account.png
|
129
|
-
[create-new-service-account-existing-keys]: https://raw.githubusercontent.com/GoogleCloudPlatform/gcloud-common/master/authentication/create-new-service-account-existing-keys.png
|
130
|
-
[reuse-service-account]: https://raw.githubusercontent.com/GoogleCloudPlatform/gcloud-common/master/authentication/reuse-service-account.png
|
131
|
-
|
132
123
|
## Creating a Service Account
|
133
124
|
|
134
125
|
Google Cloud requires **Service Account Credentials** to
|
@@ -139,31 +130,22 @@ If you are not running this client within
|
|
139
130
|
[Google Cloud Platform environments](#google-cloud-platform-environments), you
|
140
131
|
need a Google Developers service account.
|
141
132
|
|
142
|
-
1. Visit the [Google
|
133
|
+
1. Visit the [Google Cloud Console](https://console.cloud.google.com/project).
|
143
134
|
2. Create a new project or click on an existing project.
|
144
|
-
3. Activate the
|
135
|
+
3. Activate the menu in the upper left and select **APIs & Services**. From
|
145
136
|
here, you will enable the APIs that your application requires.
|
146
137
|
|
147
|
-
![Enable the APIs that your application requires][enable-apis]
|
148
|
-
|
149
138
|
*Note: You may need to enable billing in order to use these services.*
|
150
139
|
|
151
140
|
4. Select **Credentials** from the side navigation.
|
152
141
|
|
153
|
-
|
154
|
-
|
155
|
-
![Create a new service account][create-new-service-account]
|
156
|
-
|
157
|
-
![Create a new service account With Existing Keys][create-new-service-account-existing-keys]
|
158
|
-
|
159
|
-
Find the "Add credentials" drop down and select "Service account" to be
|
160
|
-
guided through downloading a new JSON key file.
|
142
|
+
Find the "Create credentials" drop down near the top of the page, and select
|
143
|
+
"Service account" to be guided through downloading a new JSON key file.
|
161
144
|
|
162
145
|
If you want to re-use an existing service account, you can easily generate a
|
163
|
-
new key file. Just select the account you wish to re-use,
|
164
|
-
|
165
|
-
|
166
|
-
![Re-use an existing service account][reuse-service-account]
|
146
|
+
new key file. Just select the account you wish to re-use, click the pencil
|
147
|
+
tool on the right side to edit the service account, select the **Keys** tab,
|
148
|
+
and then select **Add Key**.
|
167
149
|
|
168
150
|
The key file you download will be used by this library to authenticate API
|
169
151
|
requests and should be stored in a secure location.
|
data/README.md
CHANGED
@@ -37,7 +37,7 @@ request = ::Google::Cloud::Retail::V2::ListCatalogsRequest.new # (request fields
|
|
37
37
|
response = client.list_catalogs request
|
38
38
|
```
|
39
39
|
|
40
|
-
View the [Client Library Documentation](https://
|
40
|
+
View the [Client Library Documentation](https://cloud.google.com/ruby/docs/reference/google-cloud-retail-v2/latest)
|
41
41
|
for class and method documentation.
|
42
42
|
|
43
43
|
See also the [Product Documentation](https://cloud.google.com/retail/docs/apis)
|
@@ -69,6 +69,11 @@ module GRPC
|
|
69
69
|
end
|
70
70
|
```
|
71
71
|
|
72
|
+
|
73
|
+
## Google Cloud Samples
|
74
|
+
|
75
|
+
To browse ready to use code samples check [Google Cloud Samples](https://cloud.google.com/docs/samples).
|
76
|
+
|
72
77
|
## Supported Ruby Versions
|
73
78
|
|
74
79
|
This library is supported on Ruby 2.5+.
|
@@ -1,12 +1,10 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/catalog.proto
|
3
3
|
|
4
|
-
require 'google/
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
5
6
|
require 'google/api/field_behavior_pb'
|
6
7
|
require 'google/api/resource_pb'
|
7
|
-
require 'google/cloud/retail/v2/common_pb'
|
8
|
-
require 'google/cloud/retail/v2/import_config_pb'
|
9
|
-
require 'google/protobuf'
|
10
8
|
|
11
9
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
12
10
|
add_file("google/cloud/retail/v2/catalog.proto", :syntax => :proto3) do
|
@@ -397,10 +397,6 @@ module Google
|
|
397
397
|
# * UserEventService will only join events with products from branch
|
398
398
|
# \\{newBranch}.
|
399
399
|
#
|
400
|
-
# This feature is only available for users who have Retail Search enabled.
|
401
|
-
# Please submit a form [here](https://cloud.google.com/contact) to contact
|
402
|
-
# cloud sales if you are interested in using Retail Search.
|
403
|
-
#
|
404
400
|
# @overload set_default_branch(request, options = nil)
|
405
401
|
# Pass arguments to `set_default_branch` via a request object, either of type
|
406
402
|
# {::Google::Cloud::Retail::V2::SetDefaultBranchRequest} or an equivalent Hash.
|
@@ -411,7 +407,7 @@ module Google
|
|
411
407
|
# @param options [::Gapic::CallOptions, ::Hash]
|
412
408
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
413
409
|
#
|
414
|
-
# @overload set_default_branch(catalog: nil, branch_id: nil, note: nil)
|
410
|
+
# @overload set_default_branch(catalog: nil, branch_id: nil, note: nil, force: nil)
|
415
411
|
# Pass arguments to `set_default_branch` via keyword arguments. Note that at
|
416
412
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
417
413
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
@@ -424,6 +420,10 @@ module Google
|
|
424
420
|
#
|
425
421
|
# This field must be one of "0", "1" or "2". Otherwise, an INVALID_ARGUMENT
|
426
422
|
# error is returned.
|
423
|
+
#
|
424
|
+
# If there are no sufficient active products in the targeted branch and
|
425
|
+
# {::Google::Cloud::Retail::V2::SetDefaultBranchRequest#force force} is not set, a
|
426
|
+
# FAILED_PRECONDITION error is returned.
|
427
427
|
# @param note [::String]
|
428
428
|
# Some note on this request, this can be retrieved by
|
429
429
|
# {::Google::Cloud::Retail::V2::CatalogService::Client#get_default_branch CatalogService.GetDefaultBranch}
|
@@ -431,6 +431,10 @@ module Google
|
|
431
431
|
#
|
432
432
|
# This field must be a UTF-8 encoded string with a length limit of 1,000
|
433
433
|
# characters. Otherwise, an INVALID_ARGUMENT error is returned.
|
434
|
+
# @param force [::Boolean]
|
435
|
+
# If set to true, it permits switching to a branch with
|
436
|
+
# {::Google::Cloud::Retail::V2::SetDefaultBranchRequest#branch_id branch_id} even
|
437
|
+
# if it has no sufficient active products.
|
434
438
|
#
|
435
439
|
# @yield [response, operation] Access the result along with the RPC operation
|
436
440
|
# @yieldparam response [::Google::Protobuf::Empty]
|
@@ -501,10 +505,6 @@ module Google
|
|
501
505
|
# {::Google::Cloud::Retail::V2::CatalogService::Client#set_default_branch CatalogService.SetDefaultBranch}
|
502
506
|
# method under a specified parent catalog.
|
503
507
|
#
|
504
|
-
# This feature is only available for users who have Retail Search enabled.
|
505
|
-
# Please submit a form [here](https://cloud.google.com/contact) to contact
|
506
|
-
# cloud sales if you are interested in using Retail Search.
|
507
|
-
#
|
508
508
|
# @overload get_default_branch(request, options = nil)
|
509
509
|
# Pass arguments to `get_default_branch` via a request object, either of type
|
510
510
|
# {::Google::Cloud::Retail::V2::GetDefaultBranchRequest} or an equivalent Hash.
|
@@ -1,6 +1,8 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/catalog_service.proto
|
3
3
|
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
4
6
|
require 'google/api/annotations_pb'
|
5
7
|
require 'google/api/client_pb'
|
6
8
|
require 'google/api/field_behavior_pb'
|
@@ -9,7 +11,6 @@ require 'google/cloud/retail/v2/catalog_pb'
|
|
9
11
|
require 'google/protobuf/empty_pb'
|
10
12
|
require 'google/protobuf/field_mask_pb'
|
11
13
|
require 'google/protobuf/timestamp_pb'
|
12
|
-
require 'google/protobuf'
|
13
14
|
|
14
15
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
15
16
|
add_file("google/cloud/retail/v2/catalog_service.proto", :syntax => :proto3) do
|
@@ -30,6 +31,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
30
31
|
optional :catalog, :string, 1
|
31
32
|
optional :branch_id, :string, 2
|
32
33
|
optional :note, :string, 3
|
34
|
+
optional :force, :bool, 4
|
33
35
|
end
|
34
36
|
add_message "google.cloud.retail.v2.GetDefaultBranchRequest" do
|
35
37
|
optional :catalog, :string, 1
|
@@ -71,18 +71,10 @@ module Google
|
|
71
71
|
# (if branch is not explicitly set).
|
72
72
|
# * UserEventService will only join events with products from branch
|
73
73
|
# {newBranch}.
|
74
|
-
#
|
75
|
-
# This feature is only available for users who have Retail Search enabled.
|
76
|
-
# Please submit a form [here](https://cloud.google.com/contact) to contact
|
77
|
-
# cloud sales if you are interested in using Retail Search.
|
78
74
|
rpc :SetDefaultBranch, ::Google::Cloud::Retail::V2::SetDefaultBranchRequest, ::Google::Protobuf::Empty
|
79
75
|
# Get which branch is currently default branch set by
|
80
76
|
# [CatalogService.SetDefaultBranch][google.cloud.retail.v2.CatalogService.SetDefaultBranch]
|
81
77
|
# method under a specified parent catalog.
|
82
|
-
#
|
83
|
-
# This feature is only available for users who have Retail Search enabled.
|
84
|
-
# Please submit a form [here](https://cloud.google.com/contact) to contact
|
85
|
-
# cloud sales if you are interested in using Retail Search.
|
86
78
|
rpc :GetDefaultBranch, ::Google::Cloud::Retail::V2::GetDefaultBranchRequest, ::Google::Cloud::Retail::V2::GetDefaultBranchResponse
|
87
79
|
end
|
88
80
|
|
@@ -1,10 +1,10 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/common.proto
|
3
3
|
|
4
|
-
require 'google/
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
5
6
|
require 'google/api/field_behavior_pb'
|
6
7
|
require 'google/protobuf/timestamp_pb'
|
7
|
-
require 'google/protobuf'
|
8
8
|
|
9
9
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
10
10
|
add_file("google/cloud/retail/v2/common.proto", :syntax => :proto3) do
|
@@ -65,8 +65,11 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
65
65
|
optional :user_agent, :string, 3
|
66
66
|
optional :direct_user_request, :bool, 4
|
67
67
|
end
|
68
|
-
add_message "google.cloud.retail.v2.
|
69
|
-
optional :
|
68
|
+
add_message "google.cloud.retail.v2.LocalInventory" do
|
69
|
+
optional :place_id, :string, 1
|
70
|
+
optional :price_info, :message, 2, "google.cloud.retail.v2.PriceInfo"
|
71
|
+
map :attributes, :string, :message, 3, "google.cloud.retail.v2.CustomAttribute"
|
72
|
+
repeated :fulfillment_types, :string, 4
|
70
73
|
end
|
71
74
|
end
|
72
75
|
end
|
@@ -85,7 +88,7 @@ module Google
|
|
85
88
|
PriceInfo::PriceRange = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.PriceInfo.PriceRange").msgclass
|
86
89
|
Rating = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.Rating").msgclass
|
87
90
|
UserInfo = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.UserInfo").msgclass
|
88
|
-
|
91
|
+
LocalInventory = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.retail.v2.LocalInventory").msgclass
|
89
92
|
end
|
90
93
|
end
|
91
94
|
end
|
@@ -30,8 +30,7 @@ module Google
|
|
30
30
|
# Auto-completion service for retail.
|
31
31
|
#
|
32
32
|
# This feature is only available for users who have Retail Search enabled.
|
33
|
-
# Please
|
34
|
-
# cloud sales if you are interested in using Retail Search.
|
33
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
35
34
|
#
|
36
35
|
class Client
|
37
36
|
include Paths
|
@@ -144,6 +143,7 @@ module Google
|
|
144
143
|
|
145
144
|
@operations_client = Operations.new do |config|
|
146
145
|
config.credentials = credentials
|
146
|
+
config.quota_project = @quota_project_id
|
147
147
|
config.endpoint = @config.endpoint
|
148
148
|
end
|
149
149
|
|
@@ -169,8 +169,7 @@ module Google
|
|
169
169
|
# Completes the specified prefix with keyword suggestions.
|
170
170
|
#
|
171
171
|
# This feature is only available for users who have Retail Search enabled.
|
172
|
-
# Please
|
173
|
-
# cloud sales if you are interested in using Retail Search.
|
172
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
174
173
|
#
|
175
174
|
# @overload complete_query(request, options = nil)
|
176
175
|
# Pass arguments to `complete_query` via a request object, either of type
|
@@ -197,21 +196,20 @@ module Google
|
|
197
196
|
#
|
198
197
|
# The maximum number of allowed characters is 255.
|
199
198
|
# @param visitor_id [::String]
|
200
|
-
# A unique identifier for tracking visitors. For example,
|
201
|
-
# implemented with an HTTP cookie, which should be able to
|
202
|
-
# a visitor on a single device. This unique identifier
|
203
|
-
# the visitor logs in or out of the website.
|
199
|
+
# Required field. A unique identifier for tracking visitors. For example,
|
200
|
+
# this could be implemented with an HTTP cookie, which should be able to
|
201
|
+
# uniquely identify a visitor on a single device. This unique identifier
|
202
|
+
# should not change if the visitor logs in or out of the website.
|
204
203
|
#
|
205
204
|
# The field must be a UTF-8 encoded string with a length limit of 128
|
206
205
|
# characters. Otherwise, an INVALID_ARGUMENT error is returned.
|
207
206
|
# @param language_codes [::Array<::String>]
|
208
|
-
# The
|
209
|
-
# the
|
210
|
-
#
|
211
|
-
# [Tags for
|
212
|
-
#
|
213
|
-
#
|
214
|
-
# Only "en-US" is currently supported.
|
207
|
+
# The language filters applied to the output suggestions. If set, it should
|
208
|
+
# contain the language of the query. If not set, suggestions are returned
|
209
|
+
# without considering language restrictions. This is the BCP-47 language
|
210
|
+
# code, such as "en-US" or "sr-Latn". For more information, see [Tags for
|
211
|
+
# Identifying Languages](https://tools.ietf.org/html/bcp47). The maximum
|
212
|
+
# number of language codes is 3.
|
215
213
|
# @param device_type [::String]
|
216
214
|
# The device type context for completion suggestions.
|
217
215
|
# It is useful to apply different suggestions on different device types, e.g.
|
@@ -238,9 +236,9 @@ module Google
|
|
238
236
|
#
|
239
237
|
# * user-data
|
240
238
|
#
|
241
|
-
# * cloud-retail
|
242
|
-
# This option requires
|
243
|
-
#
|
239
|
+
# * cloud-retail:
|
240
|
+
# This option requires enabling auto-learning function first. See
|
241
|
+
# [guidelines](https://cloud.google.com/retail/docs/completion-overview#generated-completion-dataset).
|
244
242
|
# @param max_suggestions [::Integer]
|
245
243
|
# Completion max suggestions. If left unset or set to 0, then will fallback
|
246
244
|
# to the configured value [CompletionConfig.max_suggestions][].
|
@@ -315,11 +313,13 @@ module Google
|
|
315
313
|
##
|
316
314
|
# Bulk import of processed completion dataset.
|
317
315
|
#
|
318
|
-
# Request processing
|
316
|
+
# Request processing is asynchronous. Partial updating is not supported.
|
317
|
+
#
|
318
|
+
# The operation is successfully finished only after the imported suggestions
|
319
|
+
# are indexed successfully and ready for serving. The process takes hours.
|
319
320
|
#
|
320
321
|
# This feature is only available for users who have Retail Search enabled.
|
321
|
-
# Please
|
322
|
-
# cloud sales if you are interested in using Retail Search.
|
322
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
323
323
|
#
|
324
324
|
# @overload import_completion_data(request, options = nil)
|
325
325
|
# Pass arguments to `import_completion_data` via a request object, either of type
|
@@ -35,8 +35,7 @@ module Google
|
|
35
35
|
# Auto-completion service for retail.
|
36
36
|
#
|
37
37
|
# This feature is only available for users who have Retail Search enabled.
|
38
|
-
# Please
|
39
|
-
# cloud sales if you are interested in using Retail Search.
|
38
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
40
39
|
#
|
41
40
|
# To load this service and instantiate a client:
|
42
41
|
#
|
@@ -1,6 +1,8 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/completion_service.proto
|
3
3
|
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
4
6
|
require 'google/api/annotations_pb'
|
5
7
|
require 'google/api/client_pb'
|
6
8
|
require 'google/api/field_behavior_pb'
|
@@ -8,7 +10,6 @@ require 'google/api/resource_pb'
|
|
8
10
|
require 'google/cloud/retail/v2/common_pb'
|
9
11
|
require 'google/cloud/retail/v2/import_config_pb'
|
10
12
|
require 'google/longrunning/operations_pb'
|
11
|
-
require 'google/protobuf'
|
12
13
|
|
13
14
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
14
15
|
add_file("google/cloud/retail/v2/completion_service.proto", :syntax => :proto3) do
|
@@ -27,8 +27,7 @@ module Google
|
|
27
27
|
# Auto-completion service for retail.
|
28
28
|
#
|
29
29
|
# This feature is only available for users who have Retail Search enabled.
|
30
|
-
# Please
|
31
|
-
# cloud sales if you are interested in using Retail Search.
|
30
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
32
31
|
class Service
|
33
32
|
|
34
33
|
include ::GRPC::GenericService
|
@@ -40,16 +39,17 @@ module Google
|
|
40
39
|
# Completes the specified prefix with keyword suggestions.
|
41
40
|
#
|
42
41
|
# This feature is only available for users who have Retail Search enabled.
|
43
|
-
# Please
|
44
|
-
# cloud sales if you are interested in using Retail Search.
|
42
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
45
43
|
rpc :CompleteQuery, ::Google::Cloud::Retail::V2::CompleteQueryRequest, ::Google::Cloud::Retail::V2::CompleteQueryResponse
|
46
44
|
# Bulk import of processed completion dataset.
|
47
45
|
#
|
48
|
-
# Request processing
|
46
|
+
# Request processing is asynchronous. Partial updating is not supported.
|
47
|
+
#
|
48
|
+
# The operation is successfully finished only after the imported suggestions
|
49
|
+
# are indexed successfully and ready for serving. The process takes hours.
|
49
50
|
#
|
50
51
|
# This feature is only available for users who have Retail Search enabled.
|
51
|
-
# Please
|
52
|
-
# cloud sales if you are interested in using Retail Search.
|
52
|
+
# Please enable Retail Search on Cloud Console before using this feature.
|
53
53
|
rpc :ImportCompletionData, ::Google::Cloud::Retail::V2::ImportCompletionDataRequest, ::Google::Longrunning::Operation
|
54
54
|
end
|
55
55
|
|
@@ -1,7 +1,8 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/import_config.proto
|
3
3
|
|
4
|
-
require 'google/
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
5
6
|
require 'google/api/field_behavior_pb'
|
6
7
|
require 'google/api/resource_pb'
|
7
8
|
require 'google/cloud/retail/v2/product_pb'
|
@@ -10,7 +11,6 @@ require 'google/protobuf/field_mask_pb'
|
|
10
11
|
require 'google/protobuf/timestamp_pb'
|
11
12
|
require 'google/rpc/status_pb'
|
12
13
|
require 'google/type/date_pb'
|
13
|
-
require 'google/protobuf'
|
14
14
|
|
15
15
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
16
16
|
add_file("google/cloud/retail/v2/import_config.proto", :syntax => :proto3) do
|
@@ -182,6 +182,16 @@ module Google
|
|
182
182
|
# they took to trigger the predict request. Note that this user event detail
|
183
183
|
# won't be ingested to userEvent logs. Thus, a separate userEvent write
|
184
184
|
# request is required for event logging.
|
185
|
+
#
|
186
|
+
# Don't set
|
187
|
+
# {::Google::Cloud::Retail::V2::UserEvent#visitor_id UserEvent.visitor_id} or
|
188
|
+
# {::Google::Cloud::Retail::V2::UserInfo#user_id UserInfo.user_id} to the same
|
189
|
+
# fixed ID for different users. If you are trying to receive non-personalized
|
190
|
+
# recommendations (not recommended; this can negatively impact model
|
191
|
+
# performance), instead set
|
192
|
+
# {::Google::Cloud::Retail::V2::UserEvent#visitor_id UserEvent.visitor_id} to a
|
193
|
+
# random unique ID and leave
|
194
|
+
# {::Google::Cloud::Retail::V2::UserInfo#user_id UserInfo.user_id} unset.
|
185
195
|
# @param page_size [::Integer]
|
186
196
|
# Maximum number of results to return per page. Set this property
|
187
197
|
# to the number of prediction results needed. If zero, the service will
|
@@ -213,9 +223,12 @@ module Google
|
|
213
223
|
# * filterOutOfStockItems tag=(-"promotional")
|
214
224
|
# * filterOutOfStockItems
|
215
225
|
#
|
216
|
-
# If your filter blocks all prediction results,
|
217
|
-
#
|
218
|
-
# `strictFiltering` to
|
226
|
+
# If your filter blocks all prediction results, the API will return generic
|
227
|
+
# (unfiltered) popular products. If you only want results strictly matching
|
228
|
+
# the filters, set `strictFiltering` to True in `PredictRequest.params` to
|
229
|
+
# receive empty results instead.
|
230
|
+
# Note that the API will never return items with storageStatus of "EXPIRED"
|
231
|
+
# or "DELETED" regardless of filter choices.
|
219
232
|
# @param validate_only [::Boolean]
|
220
233
|
# Use validate only mode for this prediction query. If set to true, a
|
221
234
|
# dummy model will be used that returns arbitrary products.
|
@@ -253,7 +266,7 @@ module Google
|
|
253
266
|
# * Each resource can have multiple labels, up to a maximum of 64.
|
254
267
|
# * Each label must be a key-value pair.
|
255
268
|
# * Keys have a minimum length of 1 character and a maximum length of 63
|
256
|
-
# characters
|
269
|
+
# characters and cannot be empty. Values can be empty and have a maximum
|
257
270
|
# length of 63 characters.
|
258
271
|
# * Keys and values can contain only lowercase letters, numeric characters,
|
259
272
|
# underscores, and dashes. All characters must use UTF-8 encoding, and
|
@@ -1,12 +1,13 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/prediction_service.proto
|
3
3
|
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
4
6
|
require 'google/api/annotations_pb'
|
5
7
|
require 'google/api/client_pb'
|
6
8
|
require 'google/api/field_behavior_pb'
|
7
9
|
require 'google/cloud/retail/v2/user_event_pb'
|
8
10
|
require 'google/protobuf/struct_pb'
|
9
|
-
require 'google/protobuf'
|
10
11
|
|
11
12
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
12
13
|
add_file("google/cloud/retail/v2/prediction_service.proto", :syntax => :proto3) do
|
@@ -1,15 +1,16 @@
|
|
1
1
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
2
|
# source: google/cloud/retail/v2/product.proto
|
3
3
|
|
4
|
-
require 'google/
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
5
6
|
require 'google/api/field_behavior_pb'
|
6
7
|
require 'google/api/resource_pb'
|
7
8
|
require 'google/cloud/retail/v2/common_pb'
|
9
|
+
require 'google/cloud/retail/v2/promotion_pb'
|
8
10
|
require 'google/protobuf/duration_pb'
|
9
11
|
require 'google/protobuf/field_mask_pb'
|
10
12
|
require 'google/protobuf/timestamp_pb'
|
11
13
|
require 'google/protobuf/wrappers_pb'
|
12
|
-
require 'google/protobuf'
|
13
14
|
|
14
15
|
Google::Protobuf::DescriptorPool.generated_pool.build do
|
15
16
|
add_file("google/cloud/retail/v2/product.proto", :syntax => :proto3) do
|