You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@solr.apache.org by Ron Haines <mi...@gmail.com> on 2025/01/09 19:41:34 UTC

suggest.cfq context

Just recently started using the 'suggest.cfq' parameter.  We have 2
suggesters configured in solrconfig.xml.  Let's call one 'suggesterX' and
the other 'suggesterY'.

For suggesterX, we are using this in the 'suggester' configuration: <str
name="contextField">suggest_cfq</str>

For suggesterY, we do not use this in the 'suggester' configuration, as we
do not want to filter by any 'context'.

So, the 'suggest' request we send to Solr contains 2 &suggest.dictionary
params, one for 'suggesterX' and one for 'suggesterY'.  But, when we also
pass the &suggester.cfq parameter, we stop getting suggestions returned for
'suggesterY'.

So, it's like Solr wants to apply that &suggester.cfq' parameter to both
'suggesterX' (correctly) and 'suggesterY' (incorrectly), which must be
filtering out all of the valid matches that come from 'suggesterY'.

Is this by design?  Or, maybe I'm not understanding how to use this
'suggest context' capability?
Thanks for any help.

Ron Haines

Re: suggest.cfq context

Posted by Ron Haines <mi...@gmail.com>.
I think I've found my answer.  Unfortunately, our 'suggesterY' is
configured to use the 'lookupImpl='AnalyzingInfixLookupFactory', which
supports the suggest.cfq.  So, if this param is present, it looks like it
will be used.

So, I will see if we can find a different lookupImp, that doesn't support
the suggest.cfq, for our 'suggesterY'.

Ron Haines

On Thu, Jan 9, 2025 at 2:41 PM Ron Haines <mi...@gmail.com> wrote:

> Just recently started using the 'suggest.cfq' parameter.  We have 2
> suggesters configured in solrconfig.xml.  Let's call one 'suggesterX' and
> the other 'suggesterY'.
>
> For suggesterX, we are using this in the 'suggester' configuration: <str
> name="contextField">suggest_cfq</str>
>
> For suggesterY, we do not use this in the 'suggester' configuration, as we
> do not want to filter by any 'context'.
>
> So, the 'suggest' request we send to Solr contains 2 &suggest.dictionary
> params, one for 'suggesterX' and one for 'suggesterY'.  But, when we also
> pass the &suggester.cfq parameter, we stop getting suggestions returned for
> 'suggesterY'.
>
> So, it's like Solr wants to apply that &suggester.cfq' parameter to both
> 'suggesterX' (correctly) and 'suggesterY' (incorrectly), which must be
> filtering out all of the valid matches that come from 'suggesterY'.
>
> Is this by design?  Or, maybe I'm not understanding how to use this
> 'suggest context' capability?
> Thanks for any help.
>
> Ron Haines
>