> For the complete documentation index, see [llms.txt](https://xiaoxiami.gitbook.io/elasticsearch/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://xiaoxiami.gitbook.io/elasticsearch/ji-chu/35query-dsldslfang-shi-cha-8be229/355fu-he-cha-8be228-compound-queries/boosting-cha-xun.md).

# Boosting 查询

**boosting**查询可以用来有效地降级能匹配给定查询的结果。 与**bool**查询中的“**NOT**”子句不同，这仍然会选择包含非预期条款的文档，但会降低其总分。

```
GET /_search
{
    "query": {
        "boosting" : {
            "positive" : {
                "term" : {
                    "field1" : "value1"
                }
            },
            "negative" : {
                 "term" : {
                     "field2" : "value2"
                }
            },
            "negative_boost" : 0.2
        }
    }
}
```
