I noticed the following behavior :
The scoring seems to change with each query though there is no change to
the index. This is mainly due to issues with boost parameter
The first query gives the correct results. But if the same query is fired
mulitple time the results change
For the query : with sort as score sort
Explanations for 2 returned docs and given below. Want to understand why is
the score changing. Am I doing something wrong
"bool" : {
"must" : {
"bool" : {
"should" : [ {
"bool" : {
"must" : {
"query_string" : {
"query" : ""microsoft"",
"fields" : [ "nameTokens" ],
"analyzer" : "analyzerWithoutStop"
}
},
"boost" : 5.0
}
}, {
"bool" : {
"should" : {
"query_string" : {
"query" : ""insideview.com"",
"fields" : [ "companyDomain" ],
"analyzer" : "analyzerWithoutStop"
}
},
"boost" : 10.0
}
} ]
}
}
}
}
Explanation for first query :
3.1991732 = (MATCH) product of:
6.3983464 = (MATCH) sum of:
6.3983464 = (MATCH) weight(companyDomain:insideview.com^10.0 in 223),
product of:
0.93694496 = queryWeight(companyDomain:insideview.com^10.0), product
of:
10.0 = boost
6.8289456 = idf(docFreq=2, maxDocs=1020)
0.013720199 = queryNorm
6.8289456 = (MATCH) fieldWeight(companyDomain:insideview.com in 223),
product of:
1.0 = tf(termFreq(companyDomain:insideview.com)=1)
6.8289456 = idf(docFreq=2, maxDocs=1020)
1.0 = fieldNorm(field=companyDomain, doc=223)
0.5 = coord(1/2)
0.89017844 = (MATCH) product of:
1.7803569 = (MATCH) sum of:
1.7803569 = (MATCH) weight(nameTokens:microsoft^5.0 in 209), product of:
0.3494771 = queryWeight(nameTokens:microsoft^5.0), product of:
5.0 = boost
5.0943446 = idf(docFreq=16, maxDocs=1020)
0.013720199 = queryNorm
5.0943446 = (MATCH) fieldWeight(nameTokens:microsoft in 209), product
of:
1.0 = tf(termFreq(nameTokens:microsoft)=1)
5.0943446 = idf(docFreq=16, maxDocs=1020)
1.0 = fieldNorm(field=nameTokens, doc=209)
0.5 = coord(1/2)
For 2nd query:
2.5471714 = (MATCH) product of:
5.0943427 = (MATCH) sum of:
5.0943427 = (MATCH) weight(nameTokens:microsoft^*15625.0 *in 209),
product of:
0.99999964 = queryWeight(nameTokens:microsoft^15625.0), product of:
15625.0 = boost
5.0943446 = idf(docFreq=16, maxDocs=1020)
1.2562947E-5 = queryNorm
5.0943446 = (MATCH) fieldWeight(nameTokens:microsoft in 209), product
of:
1.0 = tf(termFreq(nameTokens:microsoft)=1)
5.0943446 = idf(docFreq=16, maxDocs=1020)
1.0 = fieldNorm(field=nameTokens, doc=209)
0.5 = coord(1/2)
0.0029293338 = (MATCH) product of:
0.0058586677 = (MATCH) sum of:
0.0058586677 = (MATCH) weight(companyDomain:insideview.com^10.0 in
223), product of:
8.5791684E-4 = queryWeight(companyDomain:insideview.com^10.0),
product of:
10.0 = boost
6.8289456 = idf(docFreq=2, maxDocs=1020)
1.2562947E-5 = queryNorm
6.8289456 = (MATCH) fieldWeight(companyDomain:insideview.com in 223),
product of:
1.0 = tf(termFreq(companyDomain:insideview.com)=1)
6.8289456 = idf(docFreq=2, maxDocs=1020)
1.0 = fieldNorm(field=companyDomain, doc=223)
0.5 = coord(1/2)
--