---------- Forwarded message ---------- From: Dmitry Bakbardin <haru_mamb...@mail.ru> Date: Wed, Apr 2, 2014 at 2:03 PM Subject: Re[2]: [xwiki-users] SearchSuggest parameters in a new syntax gives different behaviour To: Marius Dumitru Florea <mariusdumitru.flo...@xwiki.com>
Hi, Marius! See below. Wed, 2 Apr 2014 10:41:32 +0300 от Marius Dumitru Florea <mariusdumitru.flo...@xwiki.com>: On Wed, Apr 2, 2014 at 9:53 AM, Marius Dumitru Florea <mariusdumitru.flo...@xwiki.com> wrote: > Hi Dmitry, > > On Mon, Mar 31, 2014 at 5:33 AM, Dmitry Bakbardin <haru_mamb...@mail.ru> > wrote: >> Hi, all! >> >> 5.2 -> 5.4.3 Upgrade >> >> Xwiki.SearchSuggest objects were changed >> >> It was: >> type:OBJECT AND (class:XWiki.BlogPostClass) AND objcontent:(__INPUT__*) >> >> It is: >> fq=type:DOCUMENT >> fq=class:Blog.BlogPostClass >> qf=object.Blog.BlogPostClass >> >> The main difference: >> - it was "__INPUT__*" query string and >> - (as far as I understood) it is "__INPUT__" if parameter "q" is omitted >> >> The result is Solr Suggest changes it's behaviour and gives only exact >> results. >> To make Search Suggest running as it was, we have to add: "q=__INPUT__*" >> > >> Is it done by puprpose or it is a bug and I have to "jira" it? > > On purpose. I did it as part of > http://jira.xwiki.org/browse/XWIKI-10051 (check the documentation > links). The reason I dropped the * (star) is because: > > (1) Prefix matching is costly If Search Suggest is too costly, we can turn it off completely :) > (2) The search suggest is not a filter (in the sense that you have a > list of item and you type some text and it filters the items starting > with that text). Search is more complex. The search text is analysed, > stop words are removed, etc. (3) It was a fake prefix matching, because if you typed more words, only the last word was matched as prefix (not the entire text). All the other were analysed. IMHO, suggest means we prefer suggest more than exact search results. What I mean, that all languages wich have declensioin are too sensitive to the __INPUT__* search. Usual use case for such a search is: you enter root of the word and get back suggest of ALL forms of the word. Even in English, which is much less "declensionable", singular and plural is the case. E.g. "wiki" input will give only exact much and won't show "wikis". Thus, it makes Solr Sugges much less relevant. > > As you said, you can get back the previous behaviour using "q=__INPUT__*" Yes, it was the firs I did, 'cause nearly to all my search strings Solr gave me "no results". It wasn't so "severe" before the upgrade. :) IMHO, it's better to leave "__INPUT__*" in default settings and amend documentation with performance/relevancy issues tricks for Solr Suggest tuning. "*" would be useful for most use cases, and would make Suggest effective, especially for new users who start playing with XWike. I do agree, that in the high load projects it could be essential to tweak default behaviour or turn it off at all. > > Let me know what yo think, > Marius > > > >> >> >> Kind regards, >> >> Dmitry >> _______________________________________________ >> users mailing list >> users@xwiki.org >> http://lists.xwiki.org/mailman/listinfo/users Kind regards, Dmitry _______________________________________________ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users