Hi,
I'm trying to tune BM25 b and k1 values. the following works in 2.3.4:
{
"settings": {
"similarity": {
"my_bm25": {
"type": "BM25",
"b": b,
"k1": k
}
}
},
"mappings": {
docType: {
"properties": {
"title": {
"type": "string",
"similarity": "my_bm25"
},
"body": {
"type": "string",
"similarity": "my_bm25"
}
}
}
}
}
but when I ran it on elasticsearch 5.1 (i.e.: I already change the type "string" to "text") : I got the following error:
elasticsearch.exceptions.RequestError: TransportError(400, u'illegal_argument_exception', u'unknown setting [index.mappings.doc.properties.body.similarity] please check that any required plugins are installed, or check the breaking changes documentation for removed settings')
Hi Christoph,
Thanks for the respond. Like you said, It works when i create the index. But failed when I want to update the b and k1 without reindexing.
In 2.3.4 i just need to stop, update the b & k1 values then start the index again. But this routine did not work on 5.1.
I need to do this to tune the b & k1 values. reindex is not an option as it will take forever
using another k1 value. After reopeing it looks like the settings are taking effect. I'm not sure how BM25 works and whether these values affect anything for documents that have already been indexed, but I guess thats not the case. Something else must be missing on your side I guess.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.