No. The spellchecker and suggester only operate on the index (tf*idf) and do 
not account for user generated input which is what the user asks for.

You need to parse the query logs periodically index query strings and 
#occurences in the query logs as a float value (or use ExternalFileField) to 
obtain a popularity rate to sort on.

This new index can then be queried as auto suggest; n-grams are commonly used 
for this. This means both "redlands" and "reckless" are returned for the query 
"re". Sort it and you've got the desired result.

I would not recommend storing user input (the queries) and the actual 
documents in the same index, for many reasons.

> From http://wiki.apache.org/solr/Suggester :
> 
> spellcheck.onlyMorePopular=true - if this parameter is set to true then the
> suggestions will be sorted by weight ("popularity") - the count parameter
> will effectively limit this to a top-N list of best suggestions. If this is
> set to false then suggestions are sorted alphabetically.
> 
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/autocomplete-with-popularity-tp3352755p
> 3352919.html Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to