building out directive for autocomplete