Open the door wide open for Watson Assistant with “custom extensions” – an awesome progression

IBM Watson Assistant is a SaaS offering from IBM to build conversational assistants.”

IBM Watson Assistant uses artificial intelligence, which helps understand users in context and provides easy, fast, consistent, and accurate answers across various applications, devices, or channelsIBM Watson Assistant is built on natural language understanding (NLU), natural language processing (NLP), and machine learning (ML).”

The first version was already excellent, and IBM clients and partners started taking these advantages; for example, Watson Assistant was used at the International Space Station. Here are more details: CIMON brings AI to the International Space StationBased on client feedback, the IBM development and design team has created a new experience and added new functionalities to the service; for example, they expanded the integration possibilities with extensions.

In this blog post I focus especially on custom extensions development and setup.

These are the sections of the blog post

  • Custom extension
  • Live stream on YouTube related to the example
  • Summary
  • Additional resources

Custom extension

Watson Assistant does provide the integration to custom information resources by using webhooks for a long time. I also created a video about how to configure the Watson Assistant webhook integration @Crisis communication chatbot. However, the WebHook integration is limited to one post-endpoint invocation.

Now it is possible to integrate several extensions based on full REST APIs. Of course, these APIs need to be documented/specified by OpenAPI 3. This new functionality opens the door wide open for Watson Assistant using incredible, nearly unlimited possibilities of integration with custom extensions; this has impressed me deeply and shows a fantastic progression.

Here is an example image for the OpenAPI 3 specification of the Node.js extension opened in the swagger.io online editor.

That motivated me to create an example that starts from scratch, from the development of a simple REST API application to the containerization and the deployment to the cloud and the definition of an own Open API documentation.

Therefore, I created the GitHub project extension APIs with easy navigable documentation Examples to develop and configure Watson Assistant extensions APIs.

Simplified architecture dependencies

The following diagram displays the simplified architecture dependencies inside a Watson Assistant Service. We will integrate a custom extension to an assistant instance in the examples.

  1. Add custom extensions
    1. We have an assistant instance inside the Watson Assistant service.
    2.  The assistant instance simplified contains environmentsintegrations, and actions.
    3.  The integrations do contain a catalog of extensions.
    4.  The extension catalog contains Out-Of-The-Box extensions and custom extensions.
    5.  A custom extension uses an Open API specification of an application to consume the REST API provided by this application.
  2. Make a custom extension available for usage in an “action”.
    1. Add the custom extension to the environments of the assistant instance.
  3.  Use the custom extension in a step of an “action”.

This is simplified diagram related to live stream at YouTube.

I also create a one houre YouTube video that shows all steps for a Node.js application with the following content.

The links do provide a direct navigation to the section in the live stream.

  1. Introduction 01:29
  2. Local development
    • Overview of the example Node.js application 08:01
    • Clone the GitHub project to the local machine 10:29
    • Develop a Node.js application and run the application locally 12:43
    • Externalize the environment variables for the basic authentication 17:11
    • Create a container image and run the container locally 19:54
    • Push the container image to a container registry 23:18
  3. Understand the Open API specification/documentation 27:15
  4. Run the application on the IBM Cloud in Code Engine
    • Create a Code Engine project and application to run the container in the cloud 30:36
    • Configure the application in Code Engine 39:05
  5. Verify the OpenAPI documentation works 40:09
  6. Configure IBM Cloud Watson Assistant
    • Create a Watson Assistant service instance 43:38
    • Watson Assistant extension overview 45:38
    • Create an assistant instance 47:07
    • Configure the integration for the assistant instance with the extension 52:12
    • Assign the extension to an environment 54:10
    • Use the extension in a step of an action 56:40
  7. Summary 01:03:24

Summary

Again the new custom extension functionality is opening the door for Watson Assistant to consume a nearly unlimited number of integrations. Now we can combine the new functionality extensions made for Action skills with webhooks made for Dialog skills, which all the integration possible, including the out-of-the-box and the search with Watson Discovery; it feels like Watson Assistant can be used to address all business challenges.

That motivated me to create an example that starts from scratch, from the development of a simple REST API application to the containerization and the deployment to the cloud and the definition of an own Open API.

Additional resources


I hope this was useful for you and let’s see what’s next?

Greetings,

Thomas

#watsonassistant, #nodejs, #extension, #codeengine, #container, #development, #openapi, #javascript

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Blog at WordPress.com.

Up ↑

%d bloggers like this: