Short answer: the low $rankFusion scores are expected. There is not necessarily a relevance/scoring problem.
MongoDB $rankFusion uses Reciprocal Rank Fusion, not raw vector similarity or Atlas Search lexical scores. The score is roughly:
sum(weight * (1 / (60 + rank)))
Because of the 60 sensitivity constant, the values are naturally small.
For example, with the app’s default weights:
vector_weight = 0.7
lexical_weight = 0.3
If a document is ranked:
lexical rank = 1
vector rank = 2
Its rank fusion score is:
0.3 * (1 / (60 + 1)) + 0.7 * (1 / (60 + 2))
= 0.004918 + 0.011290
= 0.016208
That matches what we are seeing.
So a score like:
0.0162
can actually be a top result.
There was one bug in our score details projection.
We had:
{"$meta": "searchScoreDetails"}
But for $rankFusion, MongoDB exposes the details as:
{"$meta": "scoreDetails"}
So score_details=true was not returning useful details.
I fixed that in app.py.
Now this request:
{
"tenant_id": "pat",
"namespace_id": "pat",
"query": "MongoDB Atlas vector search rank fusion benchmark",
"limit": 1,
"score_details": true
}
returns details like:
{
"rank_fusion_score": 0.016208355367530406,
"score_details": {
"value": 0.016208355367530406,
"description": "value output by reciprocal rank fusion algorithm, computed as sum of (weight * (1 / (60 + rank))) across input pipelines from which this document is output, from:",
"details": [
{
"inputPipelineName": "lexical",
"rank": 1,
"weight": 0.3,
"value": 3.585639238357544
},
{
"inputPipelineName": "vector",
"rank": 2,
"weight": 0.7,
"value": 0.5060268640518188
}
]
}
}
This confirms the low fused score is just the RRF formula.