SearchResponseBody
- productsType: array object[] · Productsrequired
The search results.
- productType: string · Product Id
_id max length:512requiredThe unique identifier for the product.
- spellcheckType: object · Spellcheckrequired
Spellcheck results. You can use the information in this object to prompt users with the correct spelling.
- autoType: boolean · Auto Spelling Correction
_spelling _correction requiredWhether Miso has automatically corrected the misspelled search query. When this field is
true, the search result is based on the corrected spelling in thecorrected_queryfield instead of users' original search query. - correctedType: string · Corrected Query
_query requiredThe corrected spelling suggested by Miso. If no spelling error is detected, this will be the same as
original_query - correctedType: string · Corrected Query With Markups
_query _with _markups requiredThe corrected spelling suggested by Miso where the revised tokens are surrounded by the tags.
- originalType: string · Original Query
_query requiredOriginal query string
- originalType: string · Original Query With Markups
_query _with _markups requiredOriginal query with the spelling errors (if any) surrounded by the tags
- spellingType: boolean · Spelling Errors
_errors requiredWhether Miso detects any spelling errors.
- startType: integer · Startrequired
Starting offset of the search results.
- totalType: integer · Totalrequired
Total number of search hits.
- boostingType: array · Boosting Rules
_rules Boosting rules that are applied to the search results.
- boostType: string · Boost Fq
_fq Defines a query in Elasticsearch query-string syntax (Lucene) that can be used to boost a subset of products to the top of the ranking, or to specific boost positions (See
boost_positionsparameter below.) For example, the query below will promote all the relevant products whose brand isNiketo the top of recommendation list:{ "boost_fq": "brand:\"Nike\"" }For a slightly more complex example, the query below will promote the Nike products which have also been tagged as
ON SALEto the top of the ranking:{ "boost_fq": "brand:\"Nike\" AND tags:\"ON SALE\"" }It is worth mentioning that, Miso will only boost products that are relevant and have high likelihood to convert, and will not boost a low performance product only because it matches the boosting query.
Depending on your boosting rules, in certain cases, you would like to prevent recommendation results from being too monotone due to boosting. With Miso, you have two tools to do so.
First, you can specify
boost_positionsto place promoted products at specific positions in the ranking. For example, the query below will place boosted products only at the first and fourth places in the ranking (positions are 0-based), and place the remaining products in their original ranking, skipping these two positions.{ "boost_fq": "brand:\"Nike\" AND tags:\"ON SALE\"", "boost_positions": [0, 3] }The second tool is
diversification.diversificationparameter, on a best-effort basis, will try to maintain a minimum distance between products that have the same attributes. For example, the following query will place products made by the same brand apart from each other.{ "boost_fq": "brand:\"Nike\" AND tags:\"ON SALE\"", "diversification": { "brand": {"minimum_distance": 1} } } - boostType: array integer[] · Boost Positions
_positions Defines a list of 0-based positions you want to place the boosted products at.
For example, the query below will promote products whose brand is
Nikeas the top and second recommendations:{ "boost_fq": "brand:\"Nike\"", "boost_positions": [0, 1] }If
boost_positionsis not specified (which is the default behavior), all the boosted products will be ranked higher than the rest of the products. - boostType: string · Boost Rule Name
_rule _name Name of the boosting rule. Use this to identify a boosting rule in _boosted_rules in the response
- customType: array object[] · Custom Assets
_assets Custom JSON assets uploaded in Dojo.
Empty object - facetType: object · Facet Counts
_counts Facet counts
- facetType: object · Facet Fields
_fields Facet counts of each facet field
- filteringType: string · Filtering Rule
_rule Filter query that is applied to the search results.
- misoType: string · Miso IdFormat: uuid
_id Miso-generated unique Id for each recommendation or search result. Maintaining this Id for subsequent page views is important to Miso's performance as we use
miso_idto track and fine-tune the performance of personalization and search results. When a user clicks on a recommendation or search result, you should pass the associatedmiso_idto the next page view, and associate themiso_idwith the interactions that take place on the page (e.g.product_detail_page_view,add_to_cart,add_to_collection,like, etc.). In this way, Miso will learn which recommendations work and which didn't.Example:
{"misoId": "123e4567-e89b-12d3-a456-426614174000"} - partiallyType: array object[] · Partially Matched Products
_matched _products The search results that only partially match the search query.
- productType: string · Product Id
_id max length:512requiredThe unique identifier for the product.
- productType: object · Product Existence
_existence Product existence query result
- propertyType: boolean
Name
- tookType: integer · Took
Number of milliseconds Miso took to retrieve the results.
