HomeDev GuideAPI Reference
Dev GuideAPI ReferenceUser GuideGitHubNuGetDev CommunityDoc feedbackLog In

Optimizely Content Graph offers access to your data with a search engine. Relevance ranking is a crucial feature that search engines support, besides the fast retrieval performance. The most relevant results for a given query in a search engine result page (SERP) should be ranked higher than less relevant ones, and the most relevant results should be ranked to the top. Offering customization in tweaking and tuning relevance ranking can be beneficial in improving the effectiveness of searches. Web users expect that search engines are effective. Poorly configured site or e-commerce search performs poorly in terms of not only conversation rates, but a deficit in engagement and general trust in the site as whole.

## Applications of boosting

Content Graph offers relevance ranking out of the world, and gives you customization with query **boosting**. There can be business logic or domain-specific logic that significantly improves the effectiveness of some queries. Matches on some fields may be more relevant than others.

Another application with **boosting** is implementing sponsored search. Given certain matching terms in the query, you may want to expand the query with some IDs of documents (certain pages or products), so these documents appear in the top of the SERP.

## How does it work?

In the `Where` input argument of a GraphQL schema, allow each predicate that you specify to be boosted with the `boost` operator option. This is of type `Int`, but Content Graph does not support negative boosting, so the value cannot be a negative number. By default, no boosting is applied in any predicate. Since `boost` is meant to influence the relevance ranking, you should project the relevance score with the `_score` field projection.

The following example shows a query with matching on content types, but where you want to boost the `media` types to the top of the results.


The `media` content types are boosted to the top.