Query blending


Query blending generates and runs multiple variants of a query which are then blended into a single result set. Query blending can be performed based on a number of sources as defined in the -qsup query processor option. This file defines the blending rules to be applied.

Query blending sources

Query blending sources are configured by setting the -qsup query processor option.

A weighting (ranging from 0 to 1) is also defined when configuring the query blending sources.

Source qsup option Description

Spelling suggestions


Blend with suggestions returned from the spelling suggestion system.

US/UK spelling differences


Blend with US/UK spelling variants (e.g. authorise and authorize).



Blend with user-defined synonyms as defined in the blending.cfg.

Word decompounding


(Experimental) Blend with decompounded word forms (mostly for German language sites)



Synonyms query blending source

A blending.cfg can be created within a profile folder and used for the synonyms (SYNS) blending source.

Presenting a message in the search interface

When using a Freemarker template the <@fb.CheckBlending> macro can be used to provide information to the user that blending has occurred. This is included in the default template:

<#if (response.resultPacket.QSups)!?size gt 0>
	<div class="alert alert-info">
		<@fb.CheckBlending linkText="Search for <em>"+question.originalQuery+"</em> instead." tag="strong" />

Automatically include spelling suggestions when a query is run

When a query is submitted to Funnelback the query processor will automatically run the query through the spelling suggestion engine and return spelling suggestions along with the search results. This can result in a message being presented above the search results such as Did you mean suggestion. This message will be presented as long as a suggestion is returned regardless of whether or not any matching search results were returned.

It is also possible to configure Funnelback to include any generated spelling suggestions as keywords applied to the search when the query runs. This uses a feature known as query blending which enables Funnelback to run a number of parallel searches and blend the result sets together into a single set of results. Spelling suggestions are one of the possible blending sources and can be enabled as follows:

  1. On the results page that is being queried add the following query processor options: -qsup=SPEL/0.5 -spelling_blend_thresh=0.5. The qsup option tells Funnelback to run supplemental query for spelling suggestions and weights these at 0.5. The spelling blend threshold controls when a spelling suggestion will be used for a blended query. Setting this to 0.5 aligns it with the default value for returning a spelling suggestion and will ensure that if a spelling suggestion is returned it will be blended with the query. The default value has a higher threshold meaning that you will sometimes get a suggestion, but it doesn’t get blended because the threshold is higher than what is configured to return the suggestion. Query blending will take effect as soon as this setting is saved (and published).

  2. (optional) If you wish to notify the user that you have also searched for spelling suggestions you can show a message above your search results. If you are using the default template you will see a message displayed similar to Search for the original query instead presented above the results. This can be modified in the template by changing the CheckBlending macro call that is in the template.

Data model

Supplemental queries as generated by query blending are returned in the data model within the response.resultPacket.QSups element.

See also