Class: Pikuri::VectorDb::Reranker::Hit

Inherits:
Data
  • Object
show all
Defined in:
lib/pikuri/vector_db/reranker/hit.rb

Overview

A single rerank result, returned in descending score order from a reranker's #rerank.

  • indexInteger, the position in the documents array passed to #rerank; callers use it to look up text/metadata they already hold.
  • scoreFloat relevance, range model-dependent (Cohere [0.0, 1.0] via a logistic head; raw logits range further). Treat as opaque — use for ordering, not thresholding (a "0.5 cutoff" means different things to different models).

Instance Attribute Summary collapse

Instance Attribute Details

#indexObject (readonly)

Returns the value of attribute index

Returns:

  • (Object)

    the current value of index



15
16
17
# File 'lib/pikuri/vector_db/reranker/hit.rb', line 15

def index
  @index
end

#scoreObject (readonly)

Returns the value of attribute score

Returns:

  • (Object)

    the current value of score



15
16
17
# File 'lib/pikuri/vector_db/reranker/hit.rb', line 15

def score
  @score
end