create the autocomplete html as objects, not as strings