The Watson™ Explorer Engine autocomplete capability displays suggestions based on the words that are being typed as users enter a query. The autocomplete results returned to the user contain the highest ranked phrases among the autocomplete suggestions that match all of the words in the query box. Any of the phrases in the autocomplete results can then be selected and either immediately used in a search, or expanded to include additional terms via the Watson Explorer Engine query-expansion capabilities. Configuring autocomplete gives the user many benefits, including:
- Autocomplete suggestions guide the user to submit less ambiguous queries
- Long queries can be quickly entered, reducing the overall time to receive results
- Complex queries are less likely to be incorrectly entered, reducing user dependencies on dictionaries
- Hard to spell words can be suggested
- Queries that users didn't consider, but may be of use, can be suggested
Autocomplete can be configured quickly and easily: First, an autocomplete dictionary is defined by adding phrases. Phrases can be extracted from existing search collections or a list of phrases from a text file. After building the autocomplete dictionary, the Watson Explorer Engine display and API function both support delivering autocomplete results to the user.
In the Watson Explorer Engine display, autocomplete suggestions will be automatically presented to and subsequently refined by the user as a query is entered. Each word (text string separated by a space or some other punctuation) will be matched against whole words in the list of phrases in the autocomplete dictionary, and any word that is currently being input will be matched against the start of any word in the phrase.
When using autocomplete, each phrase can be matched by either any word in any position (known as a bag-of-words) or by matching an exact string against a portion of the suggestion in the same order as they appear in the suggestion, and optional filters can be defined to remove unwanted phrases from those which will be suggested.
Watson Explorer Engine autocomplete dictionaries (when produced from existing search collections) can also contain metadata which allows additional non-searchable content elements to be returned with each suggestion. This allows for extra descriptive information to be displayed in the autocomplete results, such as images, links, or descriptive text. All metadata contents are returned when using its API and therefore may be used for any purpose.
When autocomplete is used with the Watson Explorer Engine API, each phrase is returned in a <suggestion> element along with associated metadata and count information as shown below:
<suggestions query="hel" status="success"> <suggestion count="40"> <phrase>Hello world!</phrase> <metadata name="image">foo.gif</metadata> </suggestion> <suggestion count="20"> <phrase>Help me use search</phrase> <metadata name="image">search.gif</metadata> <metadata name="description">Type words into the box and click search</metadata> <metadata name="url">http://www.velocity.com</metadata> </suggestion> </suggestions>