Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-15869

expand LTRRescorer.rescore test coverage

    XMLWordPrintableJSON

Details

    • Test
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • contrib - LTR
    • None

    Description

      On the dev mailing list https://lists.apache.org/thread/113d1yzty5ryvyt2o9msfytldv41qpgq thread 4nn4r shared about the discovery of the org.apache.solr.ltr.LTRRescorer#scoreSingleHit code block and how hitUpto >= topN never arises. I agree that the condition currently never evaluates to true due to how the rescore method is called:

      This ticket here proposes to expand LTRRescorer.rescore test coverage to include the "more than topN documents are passed to be rescored" scenario.

      (Whether or not the block of code in question could/should be removed I'd like to leave out of the scope of this current ticket here since on a high level not supporting topN != firstPassTopDocs.scoreDocs.length in LTRRescorer could simplify its code but on a practical level (at least theoretically) backwards compatibility would also need consideration and it's possible that some custom ReRankCollector (which we don't know of) does for some reason not cap the number of documents passed in the way ReRankCollector does.)

      Attachments

        Issue Links

          Activity

            People

              cpoerschke Christine Poerschke
              cpoerschke Christine Poerschke
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m