일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- Python
- analyzer test
- ELASTIC
- aggs
- springboot
- token filter test
- aggregation
- license delete
- high level client
- Mac
- 900gle
- docker
- TensorFlow
- query
- Kafka
- Test
- Elasticsearch
- Java
- sort
- plugin
- flask
- matplotlib
- MySQL
- License
- licence delete curl
- zip 암호화
- API
- 차트
- 파이썬
- zip 파일 암호화
Archives
- Today
- Total
개발잡부
[es8] similarity modules 본문
반응형
Similarity module | Elasticsearch Guide [8.7] | Elastic
While scripted similarities provide a lot of flexibility, there is a set of rules that they need to satisfy. Failing to do so could make Elasticsearch silently return wrong top hits or fail with internal errors at search time:
www.elastic.co
#DFR
PUT /index
{
"settings": {
"index": {
"similarity": {
"my_similarity": {
"type": "DFR",
"basic_model": "g",
"after_effect": "l",
"normalization": "h2",
"normalization.h2.c": "3.0"
}
}
}
}
}
#BM25
PUT /index
{
"settings": {
"index": {
"similarity": {
"bm25_similarity": {
"type": "BM25",
"k1": "1",
"b": "1",
"discount_overlaps": "true"
}
}
}
}
}
#DFI
PUT /index
{
"settings": {
"index": {
"similarity": {
"bm25_similarity": {
"type": "DFI",
"independence_measure": "chisquared"
}
}
}
}
}
#IB
PUT /index
{
"settings": {
"index": {
"similarity": {
"bm25_similarity": {
"type": "IB",
"distribution": "spl",
"lambda": "df",
"normalization": "h2",
"normalization.h2.c": "3.0"
}
}
}
}
}
#LM Dirichlet
PUT /index
{
"settings": {
"index": {
"similarity": {
"bm25_similarity": {
"type": "LMDirichlet",
"mu": "2000"
}
}
}
}
}

PUT /index/_mapping
{
"properties" : {
"title" : { "type" : "text", "similarity" : "my_similarity" }
}
}

반응형
'ElasticStack8 > Elasticsearch' 카테고리의 다른 글
[es8] elasticsearch stable-esplugin (0) | 2023.05.21 |
---|---|
[es8] Elasticsearch Plugin 8.6.2 (0) | 2023.05.20 |
[es] _explain (0) | 2023.05.09 |
[es8] ignore_malformed (0) | 2023.01.23 |
[es8] index 와 shard 사이즈 (0) | 2022.10.06 |