Class VectorScorer

    • Method Detail

      • create

        static VectorScorer.FloatVectorScorer create​(LeafReaderContext context,
                                                     FieldInfo fi,
                                                     float[] query)
                                              throws java.io.IOException
        Create a new vector scorer instance.
        Parameters:
        context - the reader context
        fi - the FieldInfo for the field containing document vectors
        query - the query vector to compute the similarity for
        Throws:
        java.io.IOException
      • score

        abstract float score()
                      throws java.io.IOException
        Compute the similarity score for the current document.
        Throws:
        java.io.IOException
      • advanceExact

        abstract boolean advanceExact​(int doc)
                               throws java.io.IOException
        Throws:
        java.io.IOException