IndriScorer

abstract class IndriScorer(boost: Float) : Scorer

The Indri parent scorer that stores the boost so that IndriScorers can use the boost outside of the term.

Inheritors

Constructors

Link copied to clipboard
constructor(boost: Float)

Properties

Link copied to clipboard
Link copied to clipboard

Optional method: Tell the scorer that its iterator may safely ignore all documents whose score is less than the given minScore. This is a no-op by default.

Functions

Link copied to clipboard
open fun advanceShallow(target: Int): Int

Advance to the block of documents that contains target in order to get scoring information about this block. This method is implicitly called by and DocIdSetIterator.nextDoc on the returned doc ID. Calling this method doesn't modify the current DocIdSetIterator.docID. It returns a number that is greater than or equal to all documents contained in the current block, but less than any doc IDS of the next block. target must be >= .docID as well as all targets that have been passed to .advanceShallow so far.

Link copied to clipboard
abstract override fun docID(): Int

Returns the doc ID that is currently being scored.

Link copied to clipboard
Link copied to clipboard
abstract override fun getMaxScore(upTo: Int): Float

Return the maximum score that documents between the last target that this iterator was .advanceShallow to included and upTo included.

Link copied to clipboard
abstract override fun iterator(): DocIdSetIterator

Return a DocIdSetIterator over matching documents.

Link copied to clipboard
abstract override fun score(): Float

Returns the score of the current document matching the query.

Link copied to clipboard
abstract override fun smoothingScore(docId: Int): Float

Returns the smoothing score of the current document matching the query. This score is used when the query/term does not appear in the document, and behaves like an idf. The smoothing score is particularly important when the Scorer returns a product of probabilities so that the document score does not go to zero when one probability is zero. This can return 0 or a smoothing score.

Link copied to clipboard

Optional method: Return a TwoPhaseIterator view of this Scorer. A return value of null indicates that two-phase iteration is not supported.