I am getting suggestions that look like they have gone through a stem
filter - e.g., I get "languag" (stem of language), "amaz" (stem of amazing).
How can I prevent this behaviour? Only suggesting full words would be
desirable.
My settings and mappings looks like this:
'mappings': {
'file': {
'properties': {
'description': {
'type': 'multi_field',
'include_in_all': True,
'fields': {
'description': {
'type': 'string'
},
'partial': {
'type': 'string',
'analyzer': 'partial'
},
'full': {
'type': 'string',
'analyzer': 'full'
}
}
},
}
}
},
'settings': {
'analysis': {
'analyzer': {
'full': {
'filter': [
'asciifolding',
'filter_shingle',
'filter_stemmer',
'filter_stop',
'lowercase',
'standard',
],
'type': 'custom',
'tokenizer': 'standard'
},
'partial': {
'filter': [
'asciifolding',
'filter_ngrams',
'filter_stemmer',
'lowercase',
'standard',
],
'type': 'custom',
'tokenizer': 'standard'
}
},
'filter': {
'filter_ngrams': {
'type': 'edgeNGram',
'max_gram': 5,
'min_gram': 1
},
'filter_stop':{
'type':'stop'
},
'filter_shingle':{
'type': 'shingle',
'max_shingle_size': 5,
'min_shingle_size': 2,
'output_unigrams': 'true'
},
'filter_stemmer' : {
'name': 'english',
'type': 'stemmer'
}
}
}
}
my suggest query looks like:
'description-suggestion': {
'text' : term,
'phrase' : {
'field' : 'description',
'direct_generator': [
{
'field' : 'description',
'suggest_mode' : 'popular'
}
]
}
}
--
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/fb65b307-f03e-450b-902c-257ff054201c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.