Added support for autocompleting terms.