vespa icon indicating copy to clipboard operation
vespa copied to clipboard

Vespa Query builder forces ranking to be an object, not a key value pair

Open ean opened this issue 2 years ago • 1 comments

Describe the bug Using the Vespa query builder to specify ranking will only allow you to add child elements to the query parameter.

The quick start guide ranking=rank_albums also links to the query builder. For me it was then suprising that I could not go in there, add ranking as a parameter and specify rank_albums as its value.

To Reproduce Go to query builder (http://localhost:8080/querybuilder/), add ranking as parameter and see that you can only add child elements to it, not assign it a string value.

Expected behavior Either be told that I should use ranking.profile to specify the rank profile, or be allowed to assign ranking a string value as well as child elements.

Alternatively stop using ranking= in our documentation

Screenshots

Screenshot 2022-06-03 at 08 47 23

Vespa version 7.593.6

ean avatar Jun 03 '22 06:06 ean

... or @ldalves - this will be addressed in the new client in https://github.com/vespa-engine/vespa/tree/master/client/js/app

kkraune avatar Aug 10 '22 08:08 kkraune

In another issue, we found that the overlap of aliases / query api "parent" parameter names is just too difficult to implement, so we will keep the object structure and not support the aliases like "ranking". I agree that the documentation could instead use ranking.profile to make this clearer

kkraune avatar Oct 17 '22 12:10 kkraune