Skip to contents

Mean cosine between the reverse-generated question embeddings and the original query embedding.

Usage

morie_kamath_ch7_answer_relevance(E_g, E_o, N = NULL)

Arguments

E_g

Question embedding rows.

E_o

Query embedding.

N

Optional question count.

Value

List with estimate, similarities.

Examples

morie_kamath_ch7_answer_relevance(E_g = c(1, 2, 3, 4, 5, 6, 7, 8), E_o = 5L)
#> $estimate
#> [1] 1
#> 
#> $similarities
#> [1] 1 1 1 1 1 1 1 1
#> 
#> $n
#> [1] 8
#> 
#> $method
#> [1] "RAGAS answer relevance (Kamath Eq 7.3)"
#>