Reference documentation and code samples for the Google Cloud Recommendation Engine V1beta1 Client class PredictionResult.
PredictionResult represents the recommendation prediction results.
Generated from protobuf message google.cloud.recommendationengine.v1beta1.PredictResponse.PredictionResult
Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ id |
string
ID of the recommended catalog item |
↳ item_metadata |
array|Google\Protobuf\Internal\MapField
Additional item metadata / annotations. Possible values: * |
getId
ID of the recommended catalog item
Returns | |
---|---|
Type | Description |
string |
setId
ID of the recommended catalog item
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getItemMetadata
Additional item metadata / annotations.
Possible values:
catalogItem
: JSON representation of the catalogItem. Will be set ifreturnCatalogItem
is set to true inPredictRequest.params
.score
: Prediction score in double value. Will be set ifreturnItemScore
is set to true inPredictRequest.params
.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\MapField |
setItemMetadata
Additional item metadata / annotations.
Possible values:
catalogItem
: JSON representation of the catalogItem. Will be set ifreturnCatalogItem
is set to true inPredictRequest.params
.score
: Prediction score in double value. Will be set ifreturnItemScore
is set to true inPredictRequest.params
.
Parameter | |
---|---|
Name | Description |
var |
array|Google\Protobuf\Internal\MapField
|
Returns | |
---|---|
Type | Description |
$this |