Fuzziness stopped working after me adding synonym file to the index. It seems like , it's not possible to use them at the same time. My query:
"query": {
"dis_max": {
"queries": [{
"multi_match": {
"query": $('#searchterm').val(),
"fields": ["search_1"],
"fuzziness": "AUTO",
"operator": "and",
"max_expansions": 1
}},
{ "match": { "search_2": $('#searchterm').val() }}
]
}
}
Mappings:
"mappings": {
"objs":{
"properties": {
"o":{
"type": "string"
},
"loc":{
"type":"geo_point"
},
"search_1":{
"type": "string",
"analyzer": "synonym"
},
"search_2":{
"type": "string",
"analyzer": "synonym"
}
}
}