Class Lucene99HnswScalarQuantizedVectorsFormat

    • Constructor Detail

      • Lucene99HnswScalarQuantizedVectorsFormat

        public Lucene99HnswScalarQuantizedVectorsFormat()
        Constructs a format using default graph construction parameters
      • Lucene99HnswScalarQuantizedVectorsFormat

        public Lucene99HnswScalarQuantizedVectorsFormat​(int maxConn,
                                                        int beamWidth)
        Constructs a format using the given graph construction parameters.
        Parameters:
        maxConn - the maximum number of connections to a node in the HNSW graph
        beamWidth - the size of the queue maintained during graph construction.
      • Lucene99HnswScalarQuantizedVectorsFormat

        public Lucene99HnswScalarQuantizedVectorsFormat​(int maxConn,
                                                        int beamWidth,
                                                        int numMergeWorkers,
                                                        int bits,
                                                        boolean compress,
                                                        java.lang.Float confidenceInterval,
                                                        java.util.concurrent.ExecutorService mergeExec)
        Constructs a format using the given graph construction parameters and scalar quantization.
        Parameters:
        maxConn - the maximum number of connections to a node in the HNSW graph
        beamWidth - the size of the queue maintained during graph construction.
        numMergeWorkers - number of workers (threads) that will be used when doing merge. If larger than 1, a non-null ExecutorService must be passed as mergeExec
        bits - the number of bits to use for scalar quantization (must be between 1 and 8, inclusive)
        compress - whether to compress the vectors, if true, the vectors that are quantized with lte 4 bits will be compressed into a single byte. If false, the vectors will be stored as is. This provides a trade-off of memory usage and speed.
        confidenceInterval - the confidenceInterval for scalar quantizing the vectors, when `null` it is calculated based on the vector field dimensions. When `0`, the quantiles are dynamically determined by sampling many confidence intervals and determining the most accurate pair.
        mergeExec - the ExecutorService that will be used by ALL vector writers that are generated by this format to do the merge