Class: Google::Apis::RetailV2::GoogleCloudRetailV2PredictResponsePredictionResult
- Inherits:
-
Object
- Object
- Google::Apis::RetailV2::GoogleCloudRetailV2PredictResponsePredictionResult
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/retail_v2/classes.rb,
lib/google/apis/retail_v2/representations.rb,
lib/google/apis/retail_v2/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) ⇒ GoogleCloudRetailV2PredictResponsePredictionResult
constructor
A new instance of GoogleCloudRetailV2PredictResponsePredictionResult.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudRetailV2PredictResponsePredictionResult
Returns a new instance of GoogleCloudRetailV2PredictResponsePredictionResult.
838 839 840 |
# File 'lib/google/apis/retail_v2/classes.rb', line 838 def initialize(**args) update!(**args) end |
Instance Attribute Details
#id ⇒ String
ID of the recommended product
Corresponds to the JSON property id
828 829 830 |
# File 'lib/google/apis/retail_v2/classes.rb', line 828 def id @id end |
#metadata ⇒ Hash<String,Object>
Additional product metadata / annotations. Possible values: * product: JSON
representation of the product. Will be set if returnProduct is set to true
in PredictRequest.params. * score: Prediction score in double value. Will
be set if returnScore is set to true in PredictRequest.params.
Corresponds to the JSON property metadata
836 837 838 |
# File 'lib/google/apis/retail_v2/classes.rb', line 836 def @metadata end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
843 844 845 846 |
# File 'lib/google/apis/retail_v2/classes.rb', line 843 def update!(**args) @id = args[:id] if args.key?(:id) @metadata = args[:metadata] if args.key?(:metadata) end |