XML Configuration Reference : Search : GroupConfig
 
GroupConfig
com.exalead.search.v30.GroupConfig
Collaspes hits in search results, by grouping hits with the same values, then sorting them within a group to keep only the top N hits. The other hits for the group do not display in the search results. The GroupBy child elemement specifies the grouping criteria. The order of GroupBy child elements does not affect sort order. The SortHitsInGroupBy child elements defines lexicographical order to sort hits within the group. By default, it uses SortConfiguration order. The Aggregation child elements specify the summary operation (SUM, MIN, MAX, and so on) to perform on all hits (discarded + top/bottom N) within a group.
Parent elements:
com.exalead.search.v30.RelevanceConfig (as RelevanceConfig)
Attributes:
Name
Type
Default value
Description
topN
int
1
Maximum number of hits to display for a group. The remaining hits do not display in search results. Must be strictly positive.
Nested elements:
Name
Type
Description
Aggregation
com.exalead.search.v30.Aggregation*
Aggregation(s) to be evaluated sequentially on all the hits within a group, and stored as a virtual expression meta. To display the aggregation value in the grouped hit(s), add this meta name as a Hit content meta.
GroupBy
com.exalead.search.v30.GroupBy*
Virtual expressions used to group, or collapse, hits in search results. Hits with the same value for an expression form one group. Hits with undefined values for the expression are never grouped. If empty, displays all hits in the search results. As with any virtual expression, it requires RAM-based index fields.
SortHitsInGroupBy
com.exalead.search.v30.SortHitsInGroupBy*
Ordered list of expressions for sorting hits. The sort direction identifies the top N hits of a group. Hits with defined values are always listed higher than hits with undefined values. If empty, it uses the SortConfig by default. As with any virtual expression, it requires RAM-based index fields.