Watson Assistant search skill tutorial: set up your virtual agent to answer almost anything

Andrew Cabral
IBM watsonx Assistant
9 min readSep 22, 2021
Photo by Marten Newhall on Unsplash

You have probably noticed a lot of improvements to Watson Assistant’s search skill. Most recently, we improved the feature by adding the short-answer capability, improving extraction of question-answer pairs from FAQs, and enabling the ability to search in multiple document formats like PDFs and Word.

The search skill improves the overall performance of Watson Assistant because it eliminates the need for the designer to deal with tons of questions that are infrequent or are buried deep in documentation. When search is used properly, it can boost the performance of the assistant by answering way more questions for end users. And because it can detect and extract a few words as an answer from a longer passage, it provides a better user experience in tight spaces like web chat clients. Take a look at the video here to see a quick demo of the Search Skill in action.

Watch how Watson Assistant can return precise, concise answers with minimal effort through the improved Search Skill

Seriously, folks, turn this feature on. It will improve your virtual agents with almost no effort.

This blog post will take you through the steps of how to….

Step-by-Step:

  1. Create a Watson Discovery instance
  2. Upload documents or connect webpages to Watson Discovery
  3. Create a Watson Assistant instance
  4. Connect Watson Assistant with Discovery
  5. Begin using the new Search Skill to answer long-tail questions

Let’s get started!

1. Create a Watson Assistant instance

The first step on our journey is to log into the IBM Cloud. If you do not already have an account, create one now before moving forward.

Once logged in, you will see your IBM Cloud dashboard. On the top right corner, select Create Resource to open the IBM Cloud catalog.

On the left, you will see the IBM Cloud catalog menu. Select the AI/Machine Learning tab, which will open up a list of 21 products. Scroll down until you see Watson Discovery and select it.

Choose the region that best works for you and select the Plus plan. I live in the United States, so I chose the US-South (Dallas) region. The Watson Discovery Plus plan comes with a 30-day free trial (the Premium plan does not). When you are ready, click Create.

Back on the main Dashboard page, you can scroll down and select your resource summary. Here you can see all of the resources you have created in your IBM Cloud Account, including the Watson Discovery instance you just created.

Click on your Watson Discovery instance to bring you to the instance’s main page. Then click on Launch Watson Discovery. A new tab will open in your browser.

2. Upload documents or connect webpages to Watson Discovery

Now you can decide what files you want to upload. Watson Discovery can support many types of files, from DOC to PDFs. You can either use a data connection to upload files or upload them all from your local computer. For this example, I have files ready on my local computer. However, the use of a connection is ideal so the document can remain current. Your connection could be through Box, IBM Cloud Storage, or various other repositories.

I start by selecting New Project from the Watson Discovery Instance main page.

For Project Name, enter an appropriate name for the data set and use case. Here, I am choosing Search Skill Demo- GDPR as I am working with GDPR documents related to IBM’s Cloud Pak for Data offering. Then, select Conversational Search as your product type as we will be supplying answers to Watson Assistant. Lastly, hit Next.

Now you can select your data source. As you can see, Watson Discovery has pre-built connectors to common data repositories such as Box and Salesforce. I will upload data locally from my computer, but other upload methods can be used.

We can now create a collection for the data that we will be uploading. I have named my collection “GDPR Documents for CP4D” as this best describes the documents that I will be uploading to Watson Discovery. The collection language is English. Now, I select Next.

Next, I will upload my documents, which are a mixture of PDFs and Word Document files. I simply click on “Drag and drop files here or upload” to select the files I wish to upload. Remember that there is a max file size of 10MB.

Once you have selected the files you wish to upload, you can check on the progress of the upload by going to My Projects and selecting the project you just created. Mine was GDPR. When you open up the project, select the Manage Collections tab on the left side menu.

Then select the Collection. You will likely see that there are zero documents in your collection. That is okay. Watson Discovery is going through the documents you have selected to upload and is processing them. While Watson Discovery is working, we will start building our Watson Assistant chatbot.

3. Create a Watson Assistant instance

To create the Watson Assistant chatbot, we are going to be taking some familiar steps. First, we will log into our IBM Cloud account. Or, if you are already in the IBM Cloud account, we will navigate back over to the main landing page to select the Create resource button.

Like last time, navigate to the AI/Machine Learning product page, but select Watson Assistant.

Select the region that makes the most sense for you, then select the Plus plan. It is crucial that you choose the Plus plan as it is required to integrate Watson Assistant and Watson Discovery.

Configure your new Watson Assistant resource by giving it a name, assigning it to a resource group, and associating tags with the resource. When finished, select Create.

After the creation, you will see the resource page for the assistant. Select Launch Assistant to open up your Watson Assistant instance.

On the Watson Assistant page, click Create Assistant.

Give your assistant a name and a description. Then click Create Assistant.

Now you are looking at the main page for your assistant. It will look like this:

From here, we will create a search skill.

4. Connect Watson Assistant with Discovery

To start, we click Add search skill.

Give your skill a name and description. Then click Continue.

From the list, select your Watson Discovery instance and then click Next.

Now the search response configuration page is displayed. A preview of your search bot with the Watson Discovery instance will appear, and you can even start asking questions to your chatbot within this screen before you officially create your chatbot.

As you scroll down, there are additional features that you can customize for your chatbot. For example, you can define the text that Watson Assistant will display to the end-user when no results are found in your documents or when there is a connectivity issue. Configure these messages as you desire.

Lastly, we can adjust how Watson Assistant will display answers to the end-user in 3 unique ways. The first is to Emphasize the answer. This feature will extract, when available, a concise answer to the end user’s question from the resulting Body of text. Emphasizing the answer provides more targeted and accurate answers for natural language questions, thus reducing the time your end users will need to get the answer that they seek. Instead of Watson Assistant returning a paragraph to read through, we receive the proper, concise answer from the text.

You can adjust the number of results that are shown for the end user’s query. You can also choose result selectivity which returns more selective answers. For my purposes, I kept the number of results down to three and kept result selectivity off. Then click Create.

You have successfully created a search skill. Click the Preview button to try out your new chatbot!

5. Begin using the new Search Skill to answer long-tail questions

Now that you have uploaded your documents, start to ask questions about the topic or document types in Watson Discovery.

And that is it! It’s so easy to create a chatbot powered by IBM Watson. You can now get precise, powerful, and most importantly, relevant insights from your data.

At IBM, we don’t just focus on having industry-leading AI and Natural Language capabilities — we build our technology bottom-up for business users like you. AI technology continues to revolutionize the landscape of customer care — and IBM Watson is putting that technology in the hands of non-technical (and technical) users everywhere.

However, your chatbot experience doesn’t stop here!

You can continue to refine your Watson Assistant chatbot by creating Dialog/Action skills and configuring intents and entities. Building Dialog or Action skills will allow you to build a conversation between Watson Assistant and the end-user.

  • Watson Assistant can be easily trained to understand and address questions or requests that your end users may typically ask.
  • Building a Dialog offers a set of full-feature editor which can be used to define both your training data and the conversation, with greater control over the logical flow.
  • With the Actions builder, you can have an assistant ready to chat in less time and with less effort by composing step-by-step flows for any range of simple or complex conversations. You can learn more about Actions here: https://medium.com/ibm-watson/why-is-it-still-so-hard-to-build-a-useful-chatbot-daa46da6a00e

Try it out in minutes — sign up for a free 30-day trial today!

Remember that for the next 30 days, you have a free trial of both Watson Assistant and Watson Discovery.

Continue to explore what Watson can do for you and your enterprise. Create a chatbot powered by IBM Watson in minutes and get powerful insights from your data.

--

--