Speeding Up Elastics Search

I am new to elastics. In elasticsearch, we can use the term boost in almost all queries. I understand that it was used to change the number of documents. But I can not find its actual use. I doubt that if I use boost values ​​in some queries, this will affect the final search result or increase the ranking of documents in the index itself.

And what is the main difference between increasing the index and increasing the query.

Thanks at Advance ..!

+3
source share
2 answers

, . , , title body "Quick Brown Fox", :

{
  "query": {
    "bool": {
      "should": [
        {
          "match": {
            "title": "Quick Brown Fox"
          }
        },
        {
          "match": {
            "body": "Quick Brown Fox"
          }
        }
      ]
    }
  }
}

, , title , body, , boost title () 2:

{
  "query": {
    "bool": {
      "should": [
        {
          "match": {
            "title": {
              "query": "Quick Brown Fox",
              "boost": 2
            }
          }
        },
        {
          "match": {
            "body": "Quick Brown Fox"
          }
        }
      ]
    }
  }
}

( , match boost).

boost 2 _score - . boost, , .

, boost .

, , _score . - Elasticsearch , . , .

: . .

+8

. .

, . , , , , .

+1

All Articles