I've been trying to get the phrase suggester up and running, but something
is wrong. I don't get any results.
The search query looks like this:
{
"suggest": {
"text": "schoko",
"simple_phrase": {
"phrase": {
"analyzer": "simple",
"field": "title",
"size": 4,
"real_word_error_likelihood": 0.95,
"confidence": 2,
"gram_size": 1,
"direct_generator": [
{
"field": "title",
"suggest_mode": "always",
"min_word_len": 1
}
]
}
}
}
}
The type mapping looks like this:
{
"products": {
"properties": {
"message": {
"type": "string"
},
"image": {
"type": "string"
},
"price": {
"type": "string"
},
"source": {
"type": "string"
},
"title": {
"type": "multi_field",
"fields": {
"title": {
"type": "string"
},
"suggest": {
"type": "string",
"analyzer": "shingle_analyzer",
"store": true,
"term_vector": "with_positions_offsets"
}
}
},
"@timestamp": {
"type": "date",
"format": "dateOptionalTime"
},
"@version": {
"type": "string"
},
"deeplink": {
"type": "string"
},
"host": {
"type": "string"
},
"logstash_checksum": {
"type": "string"
},
"path": {
"type": "string"
}
}
}
}
And index settings look like this:
{
"settings": {
"analysis": {
"filter": {
"shingle_filter": {
"type": "shingle",
"min_shingle_size": 2,
"max_shingle_size": 5
}
},
"analyzer": {
"shingle_analyzer": {
"type": "custom",
"tokenizer": "standard",
"filter": [
"lowercase",
"shingle_filter"
]
}
}
}
}
}
Any ideas on what's wrong?
I'd be really grateful for any hints!
--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/ede1d487-11e8-4267-8c56-37cf82e10335%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.