Elasticsearch version 5.1 multimatch minimum should match

upgrade elasticsearch 1.7.5 to version 5.1 the search query result and scores changed. Both version have same settings and mappings, everything is the same.

`

 {
  
  "_source": {

          "includes": [

             "productName"

               ]
         },
    "size": 100, 
   "query": {
      "function_score": {
         "query": {
            "multi_match": {
               "type": "best_fields",
               "query": "karaf",
               "minimum_should_match": "100%",
               "operator": "and",
               "fields": [
                  "productName.standard"
               ]
            }
         }
      }
   }
}`

Version 1.7.5 result : https://gist.github.com/escobar4400/e45062e0e06ab251e190e2acf93f62ee

Version 5.1 result: https://gist.github.com/escobar4400/4abbe0b4760990015a632fbfa168df90

in version 1.7 when change minimum_should_match =50% ,the result document increase , but in 5.1 nothing change minimum_should_match =1% and minimum_should_match =100% same result count and same document.

mapping :

 {
"test-index": {
	"mappings": {
		"product": {
			"properties": {
				"productName": {
					"type": "keyword",
					"fields": {
						"standard": {
							"type": "text",
							"similarity": "classic",
							"analyzer": "auto_complete"
						}
					}
				},
				"seoDescription": {
					"type": "keyword",
					"fields": {
						"standard": {
							"type": "text",
							"similarity": "classic",
							"analyzer": "auto_complete"
						}
					}
				},
				"seoKeyword": {
					"type": "keyword",
					"fields": {
						"standard": {
							"type": "text",
							"similarity": "classic",
							"analyzer": "auto_complete"
						}
					}
				},
				"variantName": {
					"type": "keyword",
					"fields": {
						"standard": {
							"type": "text",
							"similarity": "classic",
							"analyzer": "auto_complete"
						}
					}
				}
			}
		}
	}
}
}

Setting :

 {
    "test-index": {
     "settings": {
        "index": {
        "analysis": {
           "filter": {
              "edge_n_gram": {
                 "type": "edge_ngram",
                 "min_gram": "3",
                 "max_gram": "10"
              },
              "synonym_filter": {
                 "type": "synonym",
                 "synonyms": [
                    ""
                 ]
              },
              "nGram": {
                 "type": "ngram",
                 "min_gram": "3",
                 "max_gram": "10"
              },
              "tr_snowball": {
                 "type": "snowball",
                 "language": "Turkish"
              }
           },
           "analyzer": {
              "auto_complete": {
                 "filter": [
                    "lowercase",
                    "asciifolding",
                    "edge_n_gram"
                 ],
                 "char_filter": [
                    "html_escape",
                    "quotes"
                 ],
                 "type": "custom",
                 "tokenizer": "whitespace"
              }
           },
           "char_filter": {
              "html_escape": {
                 "type": "html_strip"
              },
              "quotes": {
                 "type": "mapping",
                 "mappings": [
                    "'=>"
                 ]
              }
           }
        },
        "number_of_replicas": "1"
        
     }
  }
 }
}

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.