lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <>
Subject Re: AnalyzingInfixSuggestor and PrefixQuery performance difference
Date Thu, 09 Mar 2017 10:52:28 GMT
AnalyzingInfixSuggester does not use an FST; it uses a Lucene index.

It's faster because 1) it indexes leading ngrams (up to 4 characters by
default) so that short suggestions map to a TermQuery (longer suggestions
still use PrefixQuery), which is much faster than PrefixQuery, but also 2)
it uses impact sorted postings, sorting by suggest weight, so that it can
early terminate on pulling suggestions.

Mike McCandless

On Thu, Mar 9, 2017 at 2:26 AM, krish mohan <>

> hi,
> When using AnalyzingInfixSuggestor, the suggest performance is faster than
> the prefix query. How AnalyzingInfixSuggestor is faster than prefixQuery?
> Is FST constructed in different way for AnalyzingInfixSuggestor? Or any
> other reason?
> Thanks.

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message