You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2026/04/29 18:22:00 UTC

[jira] [Commented] (SOLR-17951) Optimize re-ranking based on "functions"

    [ https://issues.apache.org/jira/browse/SOLR-17951?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18077132#comment-18077132 ] 

ASF subversion and git services commented on SOLR-17951:
--------------------------------------------------------

Commit 930e6c158e9540b16dd0c8fb84972fe6fd9a5abf in solr's branch refs/heads/main from Chris M. Hostetter
[ https://gitbox.apache.org/repos/asf?p=solr.git;h=930e6c158e9 ]

SOLR-17951: Optimize re-ranking based on "functions"


> Optimize re-ranking based on "functions"
> ----------------------------------------
>
>                 Key: SOLR-17951
>                 URL: https://issues.apache.org/jira/browse/SOLR-17951
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Chris M. Hostetter
>            Assignee: Chris M. Hostetter
>            Priority: Major
>         Attachments: SOLR-17951-1.patch, SOLR-17951.patch
>
>
> Lucene 10.3 added a {{DoubleValuesSourceRescorer}} alternative to the existing {{QueryRescorer}} as way to re-rank documents based on {{DoubleValues}} w/o needing the overhead of a query wrapper.
> I took a stab at refactoring the existing logic in {{ReRankQParserPlugin}} to try and "optimize" situations where the {{reRankQuery}} is a "function" based query by unwrapping it to get the underlying {{ValueSource}} (or {{DoubleValuesSource}}) -- similar to how {{QParser.parseAsValueSource()}} avoids an unnecessary {{QueryValueSource}} wrapper if the underlying QParser returns a "function" query.
> ie: make this faster...
> {noformat}
> rq={!rerank reRankQuery=$rrq}
> rrq={!func}something(cool)
> {noformat}
> I'll attach my patch, but (un)fortunately it caused {{TestDenseVectorFunctionQuery}} to help uncover [a lucene bug|https://github.com/apache/lucene/issues/15328] in  {{VectorSimilarityFunction}} ... so we should either wait for that to be fixed, or perhaps write our own substitute for {{ValueSource.asDoubleValuesSource()}} that _explicitly_ calls {{floatVal(doc)}} to work around the issue



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org