And 7

2016.05.31 - 번역 - Lost in Translation: Boolean Operations and Filters in the Bool Query ...

With 5.0 on the horizon, a number of query types deprecated in 2.x will be removed. Many of those are replaced by functionality of the bool query, so here’s a quick guide on how to move away from filtered queries; and, or, not queries; and a general look into how to parse boolean logic with the bool query.5.0 이 출시되면서, 2.x 에서 deprecate된 많은 query 유형이 제거된다. 그들 중 많은 부분이 bool query 기능으로 대체된다. 그래서, 여기..

Blog 2019.01.07

2-2-3. Multiword Queries

If we could search for only one word at a time, full-text search would be pretty inflexible. Fortunately, the match query makes multiword queries just as simple:한번에 한 단어만을 검색할 수 있다면, full-text 검색은 아주 융통성 없는 검색일 것이다. 하지만, matchquery는 간단하게 여러 단어로 된 query를 만들 수 있다.GET /my_index/my_type/_search { "query": { "match": { "title": "BROWN DOG!" } } }COPY AS CURLVIEW IN SENSE The preceding query returns a..

2-3-5. How match Uses bool

By now, you have probably realized that multiword match queries simply wrap the generated termqueries in a bool query. With the default or operator, each term query is added as a should clause, so at least one clause must match. These two queries are equivalent:이제, 다중 단어 match query는, 생성된 term query를 단순히 bool query로 감싼 것이라는 것을 알게 되었을 것이다. 각 term query가, 기본인 or operator와 함께, should 절에 추가된다. 따라서, ..

2-3-08. Field-Centric Queries

All three of the preceding problems stem from most_fields being field-centric rather than term-centric: it looks for the most matching fields, when really what we’re interested in is the most matching terms.위의 세 가지 문제점 모두는, most_fields 가 단어 중심(term-centric) 이라기 보다는, field 중심(field-centric) 이라는 사실에서 기인한다. 실제로 관심을 가지는 것은 대부분이 일치하는 단어(terms) 인데, 대부분이 일치하는 fields 를 검색한다.The best_fields type is also ..

3-5-3. Stopwords and Performance

The biggest disadvantage of keeping stopwords is that of performance. When Elasticsearch performs a full-text search, it has to calculate the relevance _score on all matching documents in order to return the top 10 matches.불용어를 유지하는 경우의 가장 큰 단점은 성능이다. Elasticsearch가 full-text 검색을 수행할 경우, 상위 10개의 document를 반환하기 위해, 일치하는 모든 document의 relevance _score 를 계산해야 한다.While most words typically occur in m..

3-5-4. Divide and Conquer

The terms in a query string can be divided into more-important (low-frequency) and less-important (high-frequency) terms. Documents that match only the less important terms are probably of very little interest. Really, we want documents that match as many of the more important terms as possible.query string에서 단어는, 더 중요하고(낮은 빈도의), 덜 중요한(높은 빈도) 단어로 나누어진다. 덜 중요한 단어만이 일치하는 document는 아마도 관심이 아주 적을 것이..