relevanssi_phrase_synonyms

apply_filters( 'relevanssi_phrase_synonyms', boolean $phrase_synonyms )

Controls how synonyms are handled when they appear inside phrases.

Parameters

$phrase_synonyms
(boolean) If true, synonyms inside phrases create new phrases. If false, synonyms inside phrases are ignored. Default true.

More information

When there’s a synonym inside a phrase, the default behaviour in Relevanssi is to create a new phrase. Let’s assume that we have the following synonym:

stomach=gastric

If this filter hook returns true (which is the default value), a search for "stomach pain" would lead Relevanssi to search for "stomach pain" "gastric pain". If this filter hook returns false:

add_filter( 'relevanssi_phrase_synonyms', '__return_false' );

the synonym would be ignored and the search query would remain "stomach pain".