Über Open CoDE Software Wiki Diskussionen Gitlab

Skip to content

RFC: Extend the searcher and its API to weigh some origins differently based on given user preferences.

For now these are given as multiple instances of the query parameter origin_weights in the form <facet>^<weight>, e.g.

&origin_weights=/Bund^0.5&origin_weights=/Land^2

will half the score of all results with origins starting with /Bund and double the score of all results with origins starting with /Land.

Note that I decided against weighing of the source field even though this would be significantly simpler to implement as I don't think users will generally interact with the technical source names, but rather with the origins of the datasets. To work seamlessly, this also requires that the functionality supports prefixes to weight whole sub-hierarchies of origins but the additional runtime cost is actually negligible since the origins facet is small and we want to resolve textual identifiers into internal dictionary ordinals in any case.

The first and the last commits are related clean-ups which could have land separately if desired to make the review here easier.

Edited by Adam Reichold

Merge request reports