SearchScorer uses ConstantsTrait
The ArangoSearch scoring algorithms, used to select the scorer function in {@see \oihana\arango\db\operations\aqlScoredSearch()}. Both scorers rank better matches with **higher** values, so relevance sorting is always descending.
Tags
Table of Contents
Constants
- BM25 : string = 'bm25'
- Best Matching 25 (Okapi BM25) — `BM25(doc, k, b)`. The recommended general-purpose scorer; requires the `"frequency"` Analyzer feature (and `"norm"` for meaningful length normalization).
- TFIDF : string = 'tfidf'
- Term frequency–inverse document frequency — `TFIDF(doc, normalize)`.
Constants
BM25
Best Matching 25 (Okapi BM25) — `BM25(doc, k, b)`. The recommended general-purpose scorer; requires the `"frequency"` Analyzer feature (and `"norm"` for meaningful length normalization).
public
string
BM25
= 'bm25'
TFIDF
Term frequency–inverse document frequency — `TFIDF(doc, normalize)`.
public
string
TFIDF
= 'tfidf'