lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shai Erera (JIRA)" <>
Subject [jira] [Commented] (LUCENE-5370) Sorting Facets on CategoryPath (Label)
Date Sun, 02 Mar 2014 07:06:19 GMT


Shai Erera commented on LUCENE-5370:

What does sort by label mean? Do you ignore the counts/weights and just want to show the top-10
label-sorted facets? Or after you compute the top-10 facets (by weight), you want to sort
their labels?

Note that sorting by label is greatly affected by the size of the taxonomy, less by the number
of documents. Asking the taxonomy to label each ordinal will be very costly if the taxonomy
is huge (e.g. not all labels can be cached in memory) vs if it's small.

> Sorting Facets on CategoryPath (Label)
> --------------------------------------
>                 Key: LUCENE-5370
>                 URL:
>             Project: Lucene - Core
>          Issue Type: New Feature
>          Components: modules/facet
>    Affects Versions: 4.6
>            Reporter: Rob Audenaerde
>              Labels: features
> Facet support sorting through {{FacetRequest.SortOrder}}. This is used in the {{ResultSortUtils}}.
For my application it would be very nice if the facets can also be sorted on their label.

> I think this could be accomplished by altering {{FacetRequest}} with an extra enum {{SortType}},
and two extra {{Heap}}  in {{ResultSortUtils}} which instead of comparing the double value,
compare the CategoryPath.
> What do you think of this idea? Or could the same behaviour be accomplished in a different
way already?
> (btw: I tried building this patch on the trunk of lucene5.0; but I couldn't get the maven
build to build correctly. I will try again lateron on the 4.6 branch.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message