Hello,
I read about two search-as-you-type technics, one from "Definitive Guide" with edge-ngrams and another with Prefix Suggester at https://www.elastic.co/guide/en/elasticsearch/reference/current/search-suggesters-completion.html which gave an initial overview of the ES autocomplete capabilities and shed light on one possible way to do that.
This is a typical address autocompletion, which involves 5 fields : [Country, City, District, Ward, Street]
.
For example full address might be ['Canada', 'Toronto', 'East York', 'Crescent Town', 'The Market Pl']
(almost made up for illustration purposes)
Country field (for now) is excluded from the input, so query should be performed only across city, district, ward and street.
User can start typing anything that he is thinking about (true random input generator in place!):
East York
York
Crescent
Market Pl
etc.
What is the suggested approach to creating a robust and effective autocompletion solution in this situation?
Should I combine all those fields into one and use edge-ngrams?