Class: Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaPredictResponsePredictionResult
- Inherits:
-
Object
- Object
- Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaPredictResponsePredictionResult
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/retail_v2alpha/classes.rb,
lib/google/apis/retail_v2alpha/representations.rb,
lib/google/apis/retail_v2alpha/representations.rb
Overview
PredictionResult represents the recommendation prediction results.
Instance Attribute Summary collapse
-
#id ⇒ String
ID of the recommended product Corresponds to the JSON property
id
. -
#metadata ⇒ Hash<String,Object>
Additional product metadata / annotations.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudRetailV2alphaPredictResponsePredictionResult
constructor
A new instance of GoogleCloudRetailV2alphaPredictResponsePredictionResult.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudRetailV2alphaPredictResponsePredictionResult
Returns a new instance of GoogleCloudRetailV2alphaPredictResponsePredictionResult.
5057 5058 5059 |
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 5057 def initialize(**args) update!(**args) end |
Instance Attribute Details
#id ⇒ String
ID of the recommended product
Corresponds to the JSON property id
5047 5048 5049 |
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 5047 def id @id end |
#metadata ⇒ Hash<String,Object>
Additional product metadata / annotations. Possible values: * product
: JSON
representation of the product. Is set if returnProduct
is set to true in
PredictRequest.params
. * score
: Prediction score in double value. Is set if
returnScore
is set to true in PredictRequest.params
.
Corresponds to the JSON property metadata
5055 5056 5057 |
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 5055 def @metadata end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
5062 5063 5064 5065 |
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 5062 def update!(**args) @id = args[:id] if args.key?(:id) @metadata = args[:metadata] if args.key?(:metadata) end |