Struct google_recommendationengine1_beta1::api::GoogleCloudRecommendationengineV1beta1PredictRequest[][src]

pub struct GoogleCloudRecommendationengineV1beta1PredictRequest {
    pub dry_run: Option<bool>,
    pub filter: Option<String>,
    pub labels: Option<HashMap<String, String>>,
    pub page_size: Option<i32>,
    pub page_token: Option<String>,
    pub params: Option<HashMap<String, String>>,
    pub user_event: Option<GoogleCloudRecommendationengineV1beta1UserEvent>,
}

Request message for Predict method.

Activities

This type is used in activities, which are methods you may call on this type or where this type is involved in. The list links the activity name, along with information about where it is used (one of request and response).

Fields

dry_run: Option<bool>

Optional. Use dryRun mode for this prediction query. If set to true, a dummy model will be used that returns arbitrary catalog items. Note that the dryRun mode should only be used for testing the API, or if the model is not ready.

filter: Option<String>

Optional. Filter for restricting prediction results. Accepts values for tags and the filterOutOfStockItems flag. * Tag expressions. Restricts predictions to items that match all of the specified tags. Boolean operators OR and NOT are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. -"tagA" is also supported and is equivalent to NOT "tagA". Tag values must be double quoted UTF-8 encoded strings with a size limit of 1 KiB. * filterOutOfStockItems. Restricts predictions to items that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=("Red" OR "Blue") tag="New-Arrival" tag=(NOT "promotional") * filterOutOfStockItems tag=(-"promotional") * filterOutOfStockItems If your filter blocks all prediction results, nothing will be returned. If you want generic (unfiltered) popular items to be returned instead, set strictFiltering to false in PredictRequest.params.

labels: Option<HashMap<String, String>>

Optional. The labels for the predict request. * Label keys can contain lowercase letters, digits and hyphens, must start with a letter, and must end with a letter or digit. * Non-zero label values can contain lowercase letters, digits and hyphens, must start with a letter, and must end with a letter or digit. * No more than 64 labels can be associated with a given request. See https://goo.gl/xmQnxf for more information on and examples of labels.

page_size: Option<i32>

Optional. Maximum number of results to return per page. Set this property to the number of prediction results required. If zero, the service will choose a reasonable default.

page_token: Option<String>

Optional. The previous PredictResponse.next_page_token.

params: Option<HashMap<String, String>>

Optional. Additional domain specific parameters for the predictions. Allowed values: * returnCatalogItem: Boolean. If set to true, the associated catalogItem object will be returned in the PredictResponse.PredictionResult.itemMetadata object in the method response. * returnItemScore: Boolean. If set to true, the prediction 'score' corresponding to each returned item will be set in the metadata field in the prediction response. The given 'score' indicates the probability of an item being clicked/purchased given the user's context and history. * strictFiltering: Boolean. True by default. If set to false, the service will return generic (unfiltered) popular items instead of empty if your filter blocks all prediction results.

user_event: Option<GoogleCloudRecommendationengineV1beta1UserEvent>

Required. Context about the user, what they are looking at and what action they took to trigger the predict request. Note that this user event detail won't be ingested to userEvent logs. Thus, a separate userEvent write request is required for event logging.

Trait Implementations

impl Clone for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Debug for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Default for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl<'de> Deserialize<'de> for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl RequestValue for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Serialize for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

Auto Trait Implementations

impl RefUnwindSafe for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Send for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Sync for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl Unpin for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

impl UnwindSafe for GoogleCloudRecommendationengineV1beta1PredictRequest[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.