seperman / fast-autocomplete

Fast Autocomplete: When Elastcsearch suggestions are not fast and flexible enough
MIT License
271 stars 40 forks source link

How to use display names? #19

Closed ghost closed 3 years ago

ghost commented 3 years ago

Would you pls help as how to use display names?

aakash-tanwar commented 3 years ago

@seperman I also have the same question, about using display names and context in suggestions. Kindly share some examples/process through we can implement that.

seperman commented 3 years ago

Hi @aakash-tanwar and @prasadgsk-mindtree I added an example in the readme:

>>> autocomplete.words['acura']
WordValue(context={'make': 'acura'}, display='Acura', count=130123, original_key=None)
>>> autocomplete.words['acura'].display
Acura