【发布时间】:2016-01-23 05:01:44
【问题描述】:
我正在尝试解读 elasticsearch 响应中的解释 API。但是有点失落。对我来说有点难以理解。任何可以更具体地解释 JSON 的简单指针或链接?我对 TF、IDF 和 VSM 中的余弦相似度有所了解。但是需要一些关于 JSON 的更具体的指针。理想的情况是,如果我能将这个 JSON 解释为一个简单的数学表达式。
{
"_explanation": {
"value": 7.937373,
"description": "sum of:",
"details": [
{
"value": 2.4789724,
"description": "weight(FirstName:M80806 in 35) [PerFieldSimilarity], result of:",
"details": [
{
"value": 2.4789724,
"description": "score(doc=35,freq=1.0), product of:",
"details": [
{
"value": 0.37350902,
"description": "queryWeight, product of:",
"details": [
{
"value": 6.6369815,
"description": "idf(docFreq=720, maxDocs=202323)"
},
{
"value": 0.056276944,
"description": "queryNorm"
}
]
},
{
"value": 6.6369815,
"description": "fieldWeight in 35, product of:",
"details": [
{
"value": 1,
"description": "tf(freq=1.0), with freq of:",
"details": [
{
"value": 1,
"description": "termFreq=1.0"
}
]
},
{
"value": 6.6369815,
"description": "idf(docFreq=720, maxDocs=202323)"
},
{
"value": 1,
"description": "fieldNorm(doc=35)"
}
]
}
]
}
]
},
{
"value": 2.6825092,
"description": "weight(FirstName:M8086 in 35) [PerFieldSimilarity], result of:",
"details": [
{
"value": 2.6825092,
"description": "score(doc=35,freq=1.0), product of:",
"details": [
{
"value": 0.38854012,
"description": "queryWeight, product of:",
"details": [
{
"value": 6.9040728,
"description": "idf(docFreq=551, maxDocs=202323)"
},
{
"value": 0.056276944,
"description": "queryNorm"
}
]
},
{
"value": 6.9040728,
"description": "fieldWeight in 35, product of:",
"details": [
{
"value": 1,
"description": "tf(freq=1.0), with freq of:",
"details": [
{
"value": 1,
"description": "termFreq=1.0"
}
]
},
{
"value": 6.9040728,
"description": "idf(docFreq=551, maxDocs=202323)"
},
{
"value": 1,
"description": "fieldNorm(doc=35)"
}
]
}
]
}
]
},
{
"value": 2.7758915,
"description": "weight(FirstName:MHMT in 35) [PerFieldSimilarity], result of:",
"details": [
{
"value": 2.7758915,
"description": "score(doc=35,freq=1.0), product of:",
"details": [
{
"value": 0.3952451,
"description": "queryWeight, product of:",
"details": [
{
"value": 7.0232153,
"description": "idf(docFreq=489, maxDocs=202323)"
},
{
"value": 0.056276944,
"description": "queryNorm"
}
]
},
{
"value": 7.0232153,
"description": "fieldWeight in 35, product of:",
"details": [
{
"value": 1,
"description": "tf(freq=1.0), with freq of:",
"details": [
{
"value": 1,
"description": "termFreq=1.0"
}
]
},
{
"value": 7.0232153,
"description": "idf(docFreq=489, maxDocs=202323)"
},
{
"value": 1,
"description": "fieldNorm(doc=35)"
}
]
}
]
}
]
}
]
}
}
【问题讨论】:
-
这将帮助你理解得分如果不是请让我知道解释一下......lucene.apache.org/core/4_0_0/core/org/apache/lucene/search/…
标签: elasticsearch lucene tf-idf cosine-similarity