lucy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marvin Humphrey <mar...@rectangular.com>
Subject Re: [lucy-user] C library:Suggester
Date Wed, 03 May 2017 20:49:56 GMT
On Wed, May 3, 2017 at 1:06 PM, Serkan Mulayim <serkanmulayim@gmail.com> wrote:
> Thank you very much Marvin,
>
> When I type hell, I would like to get tokens starting with hell, e.g.
> {"hell","hello","helix"}. I do not want to get documents which contain hell
> token in the title. So it seems like it should be working on the tokens.
>
> What I need is basically to be able to iterate over all tokens which are
> lexicographically ordered. Also I would need to sort them based on their
> frequencies when returning the results. I guess Lexicon class,
> https://lucy.apache.org/docs/c/Lucy/Index/Lexicon.html,  is designed for
> this. Can you please confirm? I hope the returned results in the
> lucy_Lex_seek contains the frequency of the terms as well.

I stand by my recommendation of using a dedicated index because you
will almost certainly want to tune your autosuggestion results. But
feel free to play around with Lexicon and see how it works for you.

Note that depending on what Analyzer you are using for a given field,
the terms in the Lexicon may not be what you expect.

Marvin Humphrey

Mime
View raw message