Searching is all about speed, and relevance calculations
can be very expensive. As Shawn says, when you explicitly
specify sort criteria you are, in effect, taking explicit control
of ranking so scores don't need to be calculated and that
expense can be avoided.

If you need score, just specify it as a secondary or
tertiary or... criteria.

Best,
Erick

On Fri, Dec 12, 2014 at 8:22 AM, Shawn Heisey <apa...@elyograg.org> wrote:
> On 12/11/2014 9:51 PM, eakarsu wrote:
>> I am having difficulty with my sort function. With the following sort,
>> documents are not sorted by score if you can see. Why sort function is not
>> able to sort it properly?
>
> I don't know why this is surprising.  If you don't use the sort
> parameter at all, the default is "score desc" ... if you DO use the sort
> parameter, that is ignored, and the sort *only* uses the parameter(s)
> you supplied.
>
> The score for each document is not affected by the sort parameter at all
> ... the only way to affect the score is to use boosting, and if you're
> doing boosting, chances are good that you're not going to use a sort
> parameter, because you'll want it sorted by score.
>
> It's my understanding that when a sort parameter is used, the score is
> ONLY calculated when you explicitly ask for it, or you turn debug on.
> If that understanding is correct, then normally there is no performance
> penalty involved for a score calculation that won't get used.
>
> Thanks,
> Shawn
>

Reply via email to