Formula: sum_q max_d q_i . d_j
Details
Every query token keeps its own vector and is scored against its best-matching document token; the sum of those maxima is the document score. Because the interaction happens after both sides are encoded, document vectors can be indexed offline – that is the "late" in late interaction. With unit-normalised vectors a document containing the query exactly scores n_q, the largest value possible.
Examples
V <- c(1, 2, 3, 4, 5, 6, 7, 8)
Colbrt(V, V)
#> $estimate
#> [1] 8
#>
#> $scores
#> [1] 8
#>
#> $ranking
#> [1] 0
#>
#> $best
#> [1] 0
#>
#> $max_sim
#> [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8]
#> [1,] 1 1 1 1 1 1 1 1
#>
#> $nq
#> [1] 8
#>
#> $n_docs
#> [1] 1
#>
#> $method
#> [1] "ColBERT late-interaction retrieval scoring"
#>
#> attr(,"class")
#> [1] "morie_rich_result" "list"
