|
| 1 | +// This file is auto-generated |
| 2 | + |
| 3 | +package bindings |
| 4 | + |
| 5 | +// CompositeRecommendationStageParameters Binding |
| 6 | +type CompositeRecommendationStageParameters struct { |
| 7 | + // With `returnProperties=true`, property values of the recommended items are returned along with their IDs in a JSON dictionary. The acquired property values can be used to easily display the recommended items to the user. |
| 8 | + // Example response with `returnProperties` set in the `resultSettings`: |
| 9 | + // ```json |
| 10 | + // { |
| 11 | + // "recommId": "ee94fa8b-efe7-4b35-abc6-2bc3456d66ed", |
| 12 | + // "source": { |
| 13 | + // "id": "category-sport" |
| 14 | + // }, |
| 15 | + // "recomms": [ |
| 16 | + // { |
| 17 | + // "id": "article-1024", |
| 18 | + // "values": { |
| 19 | + // "title": "Champions League: Stunning Comeback Secures Final Spot", |
| 20 | + // "categories": ["Sport", "Football"], |
| 21 | + // "author": "Jane Smith", |
| 22 | + // "url": "newsportal.com/articles/champions-league-comeback" |
| 23 | + // } |
| 24 | + // }, |
| 25 | + // { |
| 26 | + // "id": "article-2031", |
| 27 | + // "values": { |
| 28 | + // "title": "Top 10 Moments from the Summer Olympics", |
| 29 | + // "categories": ["Sport", "Olympics"], |
| 30 | + // "author": "Mark Johnson", |
| 31 | + // "url": "newsportal.com/articles/olympic-top-moments" |
| 32 | + // } |
| 33 | + // }, |
| 34 | + // { |
| 35 | + // "id": "article-3042", |
| 36 | + // "values": { |
| 37 | + // "title": "Rising Stars in Women's Tennis to Watch This Season", |
| 38 | + // "categories": ["Sport", "Tennis"], |
| 39 | + // "author": "Laura Chen", |
| 40 | + // "url": "newsportal.com/articles/womens-tennis-stars" |
| 41 | + // } |
| 42 | + // } |
| 43 | + // ], |
| 44 | + // "numberNextRecommsCalls": 0 |
| 45 | + // } |
| 46 | + // ``` |
| 47 | + ReturnProperties *bool `json:"returnProperties,omitempty"` |
| 48 | + // Allows specifying which properties should be returned when `returnProperties=true` is set. The properties are given as a comma-separated list. |
| 49 | + // Example response for `returnProperties=true` and `includedProperties=title,url` set in `resultSettings`: |
| 50 | + // ```json |
| 51 | + // { |
| 52 | + // "recommId": "ee94fa8b-efe7-4b35-abc6-2bc3456d66ed", |
| 53 | + // "source": { |
| 54 | + // "id": "category-sport" |
| 55 | + // }, |
| 56 | + // "recomms": [ |
| 57 | + // { |
| 58 | + // "id": "article-1024", |
| 59 | + // "values": { |
| 60 | + // "title": "Champions League: Stunning Comeback Secures Final Spot", |
| 61 | + // "url": "newsportal.com/articles/champions-league-comeback" |
| 62 | + // } |
| 63 | + // }, |
| 64 | + // { |
| 65 | + // "id": "article-2031", |
| 66 | + // "values": { |
| 67 | + // "title": "Top 10 Moments from the Summer Olympics", |
| 68 | + // "url": "newsportal.com/articles/olympic-top-moments" |
| 69 | + // } |
| 70 | + // }, |
| 71 | + // { |
| 72 | + // "id": "article-3042", |
| 73 | + // "values": { |
| 74 | + // "title": "Rising Stars in Women's Tennis to Watch This Season", |
| 75 | + // "url": "newsportal.com/articles/womens-tennis-stars" |
| 76 | + // } |
| 77 | + // } |
| 78 | + // ], |
| 79 | + // "numberNextRecommsCalls": 0 |
| 80 | + // } |
| 81 | + // ``` |
| 82 | + IncludedProperties *[]string `json:"includedProperties,omitempty"` |
| 83 | + // Boolean-returning [ReQL](https://docs.recombee.com/reql) expression, which allows you to filter recommended entities based on the values of their attributes. |
| 84 | + // Filters can also be assigned to a [scenario](https://docs.recombee.com/scenarios) in the [Admin UI](https://admin.recombee.com). |
| 85 | + Filter *string `json:"filter,omitempty"` |
| 86 | + // Number-returning [ReQL](https://docs.recombee.com/reql) expression, which allows you to boost the recommendation rate of some entities based on the values of their attributes. |
| 87 | + // Boosters can also be assigned to a [scenario](https://docs.recombee.com/scenarios) in the [Admin UI](https://admin.recombee.com). |
| 88 | + Booster *string `json:"booster,omitempty"` |
| 89 | + // Logic specifies the particular behavior of the recommendation models. You can pick tailored logic for your domain and use case. |
| 90 | + // See [this section](https://docs.recombee.com/recommendation_logics) for a list of available logics and other details. |
| 91 | + // The difference between `logic` and `scenario` is that `logic` specifies mainly behavior, while `scenario` specifies the place where recommendations are shown to the users. |
| 92 | + // Logic can also be set to a [scenario](https://docs.recombee.com/scenarios) in the [Admin UI](https://admin.recombee.com). |
| 93 | + Logic Logic `json:"logic,omitempty"` |
| 94 | + // Only usable if the stage corresponds to the one of these recommendation endpoints: |
| 95 | + // - [Recommend Items To User](https://docs.recombee.com/api#recommend-items-to-user) |
| 96 | + // - [Recommend Items To Item](https://docs.recombee.com/api#recommend-items-to-item) |
| 97 | + // - [Recommend Items to Item Segment](https://docs.recombee.com/api#recommend-items-to-item-segment) |
| 98 | + // - [Recommend Users to Item](https://docs.recombee.com/api#recommend-users-to-item) |
| 99 | + // - [Recommend Users To User](https://docs.recombee.com/api#recommend-users-to-user) |
| 100 | + // A dictionary of [ReQL](https://docs.recombee.com/reql) expressions that will be executed for each recommended item. |
| 101 | + // This can be used to compute additional properties of the recommended items that are not stored in the database. |
| 102 | + // The keys are the names of the expressions, and the values are the actual ReQL expressions. |
| 103 | + // Example request: |
| 104 | + // ```json |
| 105 | + // { |
| 106 | + // "reqlExpressions": { |
| 107 | + // "isInUsersCity": "context_user[\"city\"] in 'cities'", |
| 108 | + // "distanceToUser": "earth_distance('location', context_user[\"location\"])" |
| 109 | + // } |
| 110 | + // } |
| 111 | + // ``` |
| 112 | + // Example response: |
| 113 | + // ```json |
| 114 | + // { |
| 115 | + // "recommId": "ce52ada4-e4d9-4885-943c-407db2dee837", |
| 116 | + // "source": { |
| 117 | + // "id": "restaurant-123", |
| 118 | + // "reqlEvaluations": { |
| 119 | + // "isInUsersCity": true, |
| 120 | + // "distanceToUser": 3450.5 |
| 121 | + // } |
| 122 | + // }, |
| 123 | + // "recomms": |
| 124 | + // [ |
| 125 | + // { |
| 126 | + // "id": "restaurant-178", |
| 127 | + // "reqlEvaluations": { |
| 128 | + // "isInUsersCity": true, |
| 129 | + // "distanceToUser": 5200.2 |
| 130 | + // } |
| 131 | + // }, |
| 132 | + // { |
| 133 | + // "id": "bar-42", |
| 134 | + // "reqlEvaluations": { |
| 135 | + // "isInUsersCity": false, |
| 136 | + // "distanceToUser": 2516.0 |
| 137 | + // } |
| 138 | + // } |
| 139 | + // ], |
| 140 | + // "numberNextRecommsCalls": 0 |
| 141 | + // } |
| 142 | + // ``` |
| 143 | + ReqlExpressions *map[string]string `json:"reqlExpressions,omitempty"` |
| 144 | + // **Expert option:** Only usable if the stage corresponds to the one of these recommendation endpoints: |
| 145 | + // - [Recommend Items To User](https://docs.recombee.com/api#recommend-items-to-user) |
| 146 | + // - [Recommend Items To Item](https://docs.recombee.com/api#recommend-items-to-item) |
| 147 | + // - [Recommend Items to Item Segment](https://docs.recombee.com/api#recommend-items-to-item-segment) |
| 148 | + // If the *userId* is provided: Specifies the threshold of how relevant must the recommended items be to the user. |
| 149 | + // Possible values one of: `"low"`, `"medium"`, `"high"`. |
| 150 | + // The default value is `"low"`, meaning that the system attempts to recommend a number of items equal to *count* at any cost. If there is not enough data (such as interactions or item properties), this may even lead to bestseller-based recommendations being appended to reach the full *count*. |
| 151 | + // This behavior may be suppressed by using `"medium"` or `"high"` values. In such case, the system only recommends items of at least the requested relevance and may return less than *count* items when there is not enough data to fulfill it. |
| 152 | + MinRelevance *string `json:"minRelevance,omitempty"` |
| 153 | + // **Expert option:** Only usable if the stage corresponds to the one of these recommendation endpoints: |
| 154 | + // - [Recommend Items To User](https://docs.recombee.com/api#recommend-items-to-user) |
| 155 | + // - [Recommend Items To Item](https://docs.recombee.com/api#recommend-items-to-item) |
| 156 | + // - [Recommend Items to Item Segment](https://docs.recombee.com/api#recommend-items-to-item-segment) |
| 157 | + // - [Recommend Users To User](https://docs.recombee.com/api#recommend-users-to-user) |
| 158 | + // If the *userId* is provided: If your users browse the system in real-time, it may easily happen that you wish to offer them recommendations multiple times. Here comes the question: how much should the recommendations change? Should they remain the same, or should they rotate? Recombee API allows you to control this per request in a backward fashion. |
| 159 | + // You may penalize an item for being recommended in the near past. For the specific user, `rotationRate=1` means maximal rotation, `rotationRate=0` means absolutely no rotation. You may also use, for example, `rotationRate=0.2` for only slight rotation of recommended items. |
| 160 | + RotationRate *float64 `json:"rotationRate,omitempty"` |
| 161 | + // **Expert option:** Only usable if the stage corresponds to the one of these recommendation endpoints: |
| 162 | + // - [Recommend Items To User](https://docs.recombee.com/api#recommend-items-to-user) |
| 163 | + // - [Recommend Items To Item](https://docs.recombee.com/api#recommend-items-to-item) |
| 164 | + // - [Recommend Items to Item Segment](https://docs.recombee.com/api#recommend-items-to-item-segment) |
| 165 | + // - [Recommend Users To User](https://docs.recombee.com/api#recommend-users-to-user) |
| 166 | + // If the *userId* is provided: Taking *rotationRate* into account, specifies how long it takes for an item to recover from the penalization. For example, `rotationTime=7200.0` means that items recommended less than 2 hours ago are penalized. |
| 167 | + RotationTime *float64 `json:"rotationTime,omitempty"` |
| 168 | +} |
0 commit comments