mirror of https://github.com/apache/lucene.git
Apply query score conversion to vector similarities in SimpleTextKnnVectorReader
This commit is contained in:
parent
c2c215d3a8
commit
84a4797d14
|
@ -159,7 +159,7 @@ public class SimpleTextKnnVectorsReader extends KnnVectorsReader {
|
|||
continue;
|
||||
}
|
||||
float[] vector = values.vectorValue();
|
||||
float score = vectorSimilarity.compare(vector, target);
|
||||
float score = vectorSimilarity.convertToScore(vectorSimilarity.compare(vector, target));
|
||||
if (vectorSimilarity.reversed) {
|
||||
score = 1 / (score + 1);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue