Search relevancy scores

Whether you tune search results for search relevancy or search merchandising purposes, we are working with their relevancy scores.

Search results are ordered by the relevancy scores of products or documents by default, from the most relevant matches to the least relevant matches. We can view the relevancy score of catalog entries in store preview with WebSphere Commerce Search. The relevancy score is displayed in search results in the following form:

Alternatively, we can view relevancy scores outside store preview by checking the trace.log log file for each document that is returned. Or we can specify debugQuery=true in the query URL in a web browser and observing the response.

WebSphere Commerce Search calculates relevancy scores by default by using several factors, including:


Calculating relevancy scores using the Lucene scoring model

The Lucene scoring model is also known as the tf-idf model. It involves a number of scoring factors:


Boosting relevancy scores

Site administrators can increase relevancy scores, for example, by changing the relevancy of search index fields, since depending on the store catalog, some search index fields might be more relevant than others for when shoppers search in the store.

Business users can increase relevancy scores, for example, by working with search term associations and search rules in the Management Center. These changes use query time boosts for specific indexed fields when constructing a search query.


Example

When you view the relevancy scores of the following products in the Aurora starter store:

The following search results are displayed when you search for red apple in the storefront:

Where the search results are displayed in the order of their relevancy, with red delicious apples displayed first.

In store preview, the search results page displays the relevancy scores after you click Show Page Information, showing why the search results are ordered in this way to the shopper: