Skip to content

Add system test for sorting on rank features - #5002

Merged
arnej27959 merged 1 commit into
masterfrom
arnej/sorting-rankfeatures-system-test
Aug 31, 2026
Merged

Add system test for sorting on rank features#5002
arnej27959 merged 1 commit into
masterfrom
arnej/sorting-rankfeatures-system-test

Conversation

@arnej27959

Copy link
Copy Markdown
Member

Covers the new sort-features rank profile block and the corresponding sortspec=feature() / YQL order by [{"function": "feature"}] query syntax:

  • single-level sorting, including that feature sorting defaults to ascending while attribute sorting takes its default from the schema
  • multi-level sorting mixing feature, attribute and [rank] levels, plus the same feature used on two levels
  • relevance stays 0 when sorting by a feature alone, and comes back when [rank] is part of the sort spec, also for a profile with a second phase
  • sort-features are inherited, and an empty block clears them
  • errors: feature not declared sortable, profile without sort-features, inherited sort-features cleared, illegal feature name, missing() combined with feature(), and a streaming schema

Covers the new sort-features rank profile block and the corresponding
sortspec=feature(<name>) / YQL order by [{"function": "feature"}] query
syntax:

 - single-level sorting, including that feature sorting defaults to
   ascending while attribute sorting takes its default from the schema
 - multi-level sorting mixing feature, attribute and [rank] levels, plus
   the same feature used on two levels
 - relevance stays 0 when sorting by a feature alone, and comes back when
   [rank] is part of the sort spec, also for a profile with a second phase
 - sort-features are inherited, and an empty block clears them
 - errors: feature not declared sortable, profile without sort-features,
   inherited sort-features cleared, illegal feature name, missing()
   combined with feature(), and a streaming schema

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

@hmusum hmusum left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great!

@radu-gheorghe radu-gheorghe left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Thanks!

@arnej27959
arnej27959 merged commit be736a4 into master Aug 31, 2026
3 checks passed
@arnej27959
arnej27959 deleted the arnej/sorting-rankfeatures-system-test branch August 31, 2026 10:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants