generated from amazon-archives/__template_Custom
-
Notifications
You must be signed in to change notification settings - Fork 179
Closed
Description
Related design is presented in issue #182
Todo list
- Support the
commonfunctionality by pushing it down to the search engine - Enable
commonfunction in SQL and PPL syntax and parser, including all the available parameters - Make sure the function in new engine is compatible with the old engine support
- Add unit tests. (Unit tests are mandatory for all code changes.)
- Add integration test cases for
common - Update user manual
Function details
The common function maps to the common terms query used in the search engine. This query is a modern alternative to stopwords which improves the precision and recall of search results (by taking stopwords into account), without sacrificing performance.
Syntax:
common(field_expression, query_expression[, option=<option_value>]*)
Available options:
- analyzer
- cutoff_frequency
- high_frequency_operator
- low_frequency_operator
- minimum_should_match
- boost
Sample query:
# Search query 1
GET my_index/_search
{
"query": {
"common": {
"message": {
"query": "this is bonsai cool",
"cutoff_frequency": 0.001
}
}
}
}
# SQL
SELECT * FROM my_index WHERE common(message, "this is bonsai cool", cutoff_frequency=0.001)
# PPL
source=my_index | where common(message, "this is bonsai cool", cutoff_frequency=0.001)
Metadata
Metadata
Assignees
Labels
No labels