2016-06-13 5 views
0

私は弾性バージョン1.6から2.3にアップグレードしていますが、残念なことに私はまったく同じクエリで採点メカニズムに大きな変化を見ました。異なるスコア1.6と2.3の間

弾性1.6:

{ 
     "value": 0.2062798, 
     "description": "ConstantScore(tags: \u0001\u0000\u0000\u0000\u0000\u0000\u00058o>)^79.65, product of:", 
     "details": [{ 
     "value": 79.65, 
     "description": "boost" 
     }, { 
     "value": 0.0025898279, 
     "description": "queryNorm" 
     }] 
    } 

弾性2.3:ここ

{ 
     "value": 3.2230546, 
     "description": "weight(tags: \u0001\u0000\u0000\u0000\u0000\u0000\u00058o> in 9071) [PerFieldSimilarity], result of:", 
     "details": [{ 
     "value": 3.2230546, 
     "description": "score(doc=9071,freq=1.0), product of:", 
     "details": [{ 
      "value": 0.2972071,`enter code here` 
      "description": "queryWeight, product of:", 
      "details": [{ 
      "value": 79.65, 
      "description": "boost", 
      "details": [] 
      }, { 
      "value": 10.844475, 
      "description": "idf(docFreq=119, maxDocs=2262468)", 
      "details": [] 
      }, { 
      "value": 0.00034408428, 
      "description": "queryNorm", 
      "details": [] 
      }] 
     }, { 
      "value": 10.844475, 
      "description": "fieldWeight in 9071, product of:", 
      "details": [{ 
      "value": 1, 
      "description": "tf(freq=1.0), with freq of:", 
      "details": [{ 
       "value": 1, 
       "description": "termFreq=1.0", 
       "details": [] 
      }] 
      }, { 
      "value": 10.844475, 
      "description": "idf(docFreq=119, maxDocs=2262468)", 
      "details": [] 
      }, { 
      "value": 1, 
      "description": "fieldNorm(doc=9071)", 
      "details": [] 
      }] 
     }] 
     }] 
    } 

は、私が使用したクエリです:

{ 
"query": { 
     "bool": { 
     "should": [ 
      { 
       "bool": { 
        "should": [ 
        { 
         "constant_score": { 
          "filter": { 
           "terms": { 
           "path": [ 
            "1489", 
            "1456", 
            "10125", 
            "11498", 
            "11264", 
            "12987", 
            "12156" 
           ] 
           } 
          }, 
          "boost": 150 
         } 
        }, 
        { 
         "bool": { 
          "should": [ 
           { 
           "term": { 
            "path": { 
             "value": "1389", 
             "boost": 11 
            } 
           } 
           }, 
           { 
           "term": { 
            "path": { 
             "value": "31016", 
             "boost": 19.8 
            } 
           } 
           }, 
           { 
           "term": { 
            "path": { 
             "value": "31153", 
             "boost": 237.4 
            } 
           } 
           } 
          ], 
          "disable_coord": true 
         } 
        } 
        ], 
        "disable_coord": true 
       } 
      } 
     ] 
     } 
    } 
} 
+0

まったく同じ文書セットがありますか?あなたもあなたの質問を共有できますか? – Val

+0

同じdocsと私は、質問に感謝、感謝を追加しました。 – Itai

答えて

0

結局のところここ

を説明ですその弾性はtを変えた彼の行動、数値フィールドのクエリは自動的に一定のスコアに使用されます。 2.x以降ではtf/idfを使用しています。

バージョン5では、一定のスコアに戻る必要があります。

関連する問題