Implementation of autocomplete for search