benwtrent commented on code in PR #12434: URL: https://github.com/apache/lucene/pull/12434#discussion_r1274931211
########## lucene/core/src/java/org/apache/lucene/codecs/KnnVectorsReader.java: ########## @@ -79,14 +80,13 @@ protected KnnVectorsReader() {} * * @param field the vector field to search * @param target the vector-valued query - * @param k the number of docs to return + * @param knnResults a KnnResults collector and relevant settings for gathering vector results * @param acceptDocs {@link Bits} that represents the allowed documents to match, or {@code null} * if they are all allowed to match. - * @param visitedLimit the maximum number of nodes that the search is allowed to visit * @return the k nearest neighbor documents, along with their (similarity-specific) scores. */ public abstract TopDocs search( - String field, float[] target, int k, Bits acceptDocs, int visitedLimit) throws IOException; + String field, float[] target, KnnResults knnResults, Bits acceptDocs) throws IOException; Review Comment: 🤔 that seems ok to me. ########## lucene/core/src/java/org/apache/lucene/codecs/KnnVectorsReader.java: ########## @@ -79,14 +80,13 @@ protected KnnVectorsReader() {} * * @param field the vector field to search * @param target the vector-valued query - * @param k the number of docs to return + * @param knnResults a KnnResults collector and relevant settings for gathering vector results * @param acceptDocs {@link Bits} that represents the allowed documents to match, or {@code null} * if they are all allowed to match. - * @param visitedLimit the maximum number of nodes that the search is allowed to visit * @return the k nearest neighbor documents, along with their (similarity-specific) scores. */ public abstract TopDocs search( - String field, float[] target, int k, Bits acceptDocs, int visitedLimit) throws IOException; + String field, float[] target, KnnResults knnResults, Bits acceptDocs) throws IOException; Review Comment: 🤔 that seems ok to me. ########## lucene/core/src/java/org/apache/lucene/codecs/KnnVectorsReader.java: ########## @@ -79,14 +80,13 @@ protected KnnVectorsReader() {} * * @param field the vector field to search * @param target the vector-valued query - * @param k the number of docs to return + * @param knnResults a KnnResults collector and relevant settings for gathering vector results * @param acceptDocs {@link Bits} that represents the allowed documents to match, or {@code null} * if they are all allowed to match. - * @param visitedLimit the maximum number of nodes that the search is allowed to visit * @return the k nearest neighbor documents, along with their (similarity-specific) scores. */ public abstract TopDocs search( - String field, float[] target, int k, Bits acceptDocs, int visitedLimit) throws IOException; + String field, float[] target, KnnResults knnResults, Bits acceptDocs) throws IOException; Review Comment: 🤔 that seems ok to me. I don't have a strong opinion. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org