Lucene104ScalarQuantizedVectorScorer (Lucene 10.5.1 core API)
Description: declaration: package: org.apache.lucene.codecs.lucene104, class: Lucene104ScalarQuantizedVectorScorer

Package org.apache.lucene.codecs.lucene104

# Class Lucene104ScalarQuantizedVectorScorer

java.lang.Object
org.apache.lucene.codecs.lucene104.Lucene104ScalarQuantizedVectorScorer

All Implemented Interfaces:
  `FlatVectorsScorer`

public class Lucene104ScalarQuantizedVectorScorer extends Object implements FlatVectorsScorer
Vector scorer over OptimizedScalarQuantized vectors

WARNING: This API is experimental and might change in incompatible ways in the next release.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Lucene104ScalarQuantizedVectorScorer(FlatVectorsScorer nonQuantizedDelegate)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `RandomVectorScorer`
  `getRandomVectorScorer(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues, byte[] target)`
  Returns a `RandomVectorScorer` for the given set of vectors and target vector.
  `RandomVectorScorer`
  `getRandomVectorScorer(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues, float[] target)`
  Returns a `RandomVectorScorer` for the given set of vectors and target vector.
  `RandomVectorScorerSupplier`
  `getRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues)`
  Returns a `RandomVectorScorerSupplier` that can be used to score vectors
  `RandomVectorScorerSupplier`
  `getRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, QuantizedByteVectorValues scoringVectors, QuantizedByteVectorValues targetVectors)`
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### Lucene104ScalarQuantizedVectorScorer

    public Lucene104ScalarQuantizedVectorScorer(FlatVectorsScorer nonQuantizedDelegate)

- ## Method Details

  - ### getRandomVectorScorerSupplier

    public RandomVectorScorerSupplier getRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues) throws IOException
    Description copied from interface: `FlatVectorsScorer`
    Returns a `RandomVectorScorerSupplier` that can be used to score vectors
    Specified by:
      `getRandomVectorScorerSupplier` in interface `FlatVectorsScorer`
    Parameters:
      `similarityFunction` - the similarity function to use
      `vectorValues` - the vector values to score
    Returns:
      a `RandomVectorScorerSupplier` that can be used to score vectors
    Throws:
      `IOException` - if an I/O error occurs

  - ### getRandomVectorScorer

    public RandomVectorScorer getRandomVectorScorer(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues, float[] target) throws IOException
    Description copied from interface: `FlatVectorsScorer`
    Returns a `RandomVectorScorer` for the given set of vectors and target vector.
    Specified by:
      `getRandomVectorScorer` in interface `FlatVectorsScorer`
    Parameters:
      `similarityFunction` - the similarity function to use
      `vectorValues` - the vector values to score
      `target` - the target vector
    Returns:
      a `RandomVectorScorer` for the given field and target vector.
    Throws:
      `IOException` - if an I/O error occurs when reading from the index.

  - ### getRandomVectorScorer

    public RandomVectorScorer getRandomVectorScorer(VectorSimilarityFunction similarityFunction, KnnVectorValues vectorValues, byte[] target) throws IOException
    Description copied from interface: `FlatVectorsScorer`
    Returns a `RandomVectorScorer` for the given set of vectors and target vector.
    Specified by:
      `getRandomVectorScorer` in interface `FlatVectorsScorer`
    Parameters:
      `similarityFunction` - the similarity function to use
      `vectorValues` - the vector values to score
      `target` - the target vector
    Returns:
      a `RandomVectorScorer` for the given field and target vector.
    Throws:
      `IOException` - if an I/O error occurs when reading from the index.

  - ### getRandomVectorScorerSupplier

    public RandomVectorScorerSupplier getRandomVectorScorerSupplier(VectorSimilarityFunction similarityFunction, QuantizedByteVectorValues scoringVectors, QuantizedByteVectorValues targetVectors)

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`