New api for autocomplete.