This documentation supports the 20.08 version of BMC Helix Chatbot.
To view the documentation for the previous version, select 20.02 from the Product version menu.

Configuring the dialog nodes to enable transfer between chatbots

If you have multiple chatbots for each line-of-business or locale, administrators can train IBM Watson Assistant Skills, so that a chat conversation is automatically transferred to another relevant chatbot. For example, if an end-user asks an HR-related question to IT Chatbot, the IT Chatbot automatically transfers the conversation to HR Chatbot. To read about the scenario and an example of conversation transfer between chatbots, see Utilizing multiple chatbots for each line of business

How chatbot transfer works between different lines-of-business chatbots

BMC Helix Chatbot provides Transfer Chatbot Template with the out-of-the-box IBM Watson Assistant Skills. The template includes a dialog node to enable transfer to another chatbot.

After the IBM Watson Assistant Skills is configured, the chatbot automatically transfers the conversation to another chatbot with the following message:

Let me route you to the <chatbot name> who can help you with that.

Important

If the chatbot transfer is configured in one of the following ways, an error is generated and the conversation is not transferred.

  • For the same intent, transferring to the same chatbot from which transfer is initiated. For example, for intent I, Bot A transfers to Bot B and Bot B transfers back to Bot A.
  • For the same intent, transferring from one chatbot to the second chatbot and then the third chatbot. For example, for intent I, Bot A transfers to Bot B and Bot B further transfers to Bot C.

See how to test transfer chatbot configuration.

How chatbot transfer works when chatbot Skills are not trained

If the chatbot Skills are not trained for transfer, the end-user sees a list of available chatbots. To disable the list of chatbots, see To disable the list of chatbots to manually transfer a conversationThe end user can then manually select a chatbot to transfer the conversation.

If the list of chatbots is disabled, the chatbot displays the knowledge articles related to the query. 

How chatbot transfer works between multiple localized chatbots

The behavior of chatbot transfer between these chatbots changes according to the way you have configured localization for chatbots:

Chatbot transfer if you have multiple IBM Watson Assistant Skills for each locale

If you have multiple chatbots and each chatbot has localized IBM Watson Assistant Skills, then one of the following conditions must be true to ensure that a conversation can be transferred to another chatbot:

  • The user locale must match the chatbot Skills locale.
  • If the chatbot Skills is configured with only one locale, then the chatbot is available for transfer even if the user locale does not match.
  • If multiple localized chatbot Skills are configured, and the user locale does not match with the localized Skills, then only the English chatbot is available for transfer. If English chatbot is not configured and the user locale does not match with the localized Skills, then that chatbot is not available for transfer.

For example, consider that you have the following chatbots:

  • BMC chatbot

  • IT chatbot

  • HR chatbot

  • French-HR chatbot

Each chatbot has localized  Skills for English, French, and German.

The following table shows whether a conversation can be transferred to another chatbot based on the user's locale:

Chatbot Configuration

User Locale

Chatbot Name

Localized Skills

English (en)

French (fr)

German (de)

Japanese (ja)

BMC Chatbot

English (en)

(tick)

(error)

(error)

(tick)

French (fr)

(error)

(tick)(error)(error)

German (de)

(error)

(error)(tick)(error)

IT

German (de)

(error)

(error)

(tick)

(error)

French (fr)

(error)

(tick)

(error)

(error)

HR

English (en)

(tick)

(tick)

(error)

(tick)

German (de)

(error)

(error)

(tick)

(error)

French-HR

French (fr)

(tick)

(tick)

(tick)

(tick)

For instance, the above table shows that if the user locale is Japanese, then the end user can transfer a conversation to the following chatbots:

  • BMC Chatbot configured in English locale
  • HR chatbot configured in English locale
  • French-HR chatbot

Chatbot transfer if you have enabled real-time translation

If you you have IBM Watson Assistant Skills for certain locales and have also enabled real-time translation for another locale, then a user conversation can be transferred to that chatbot.

For example, consider that you have the following chatbots:

  • BMC Chatbot

  • IT chatbot

  • HR chatbot

  • French-HR chatbot

You have localized Skills for English and French and have enabled real-time translation in German for BMC Chatbot.

The following table shows whether a conversation can be transferred to another chatbot based on the user's locale:

Chatbot Configuration

User Locale

Chatbot Name

Localized Skills

Real-time translation

English (en)

French (fr)

German (de)

Japanese (ja)

BMC Chatbot

English (en)

-

(tick)

(error)

(error)

(error)

French (fr)

-

(error)

(tick)(error)(error)

German (de)

Enabled

(error)

(error)(tick)(tick)

IT

German (de)

-

(error)

(error)

(tick)

(error)

French (fr)

-

(error)

(tick)

(error)

(error)

HR

English (en)

-

(tick)

(tick)

(error)

(tick)

German (de)


(error)

(error)

(tick)

(error)

French-HR

French (fr)

-

(tick)

(tick)

(tick)

(tick)

For instance, the above table shows that if the user locale is German, then the end user can transfer a conversation to the following chatbots:

  • BMC Chatbot configured in German locale for which real-time translation is enabled and the primary language is German.
  • HR chatbot configured in English locale
  • French-HR chatbot

Before you begin

To add intents to specify when you want to trigger the chatbot transfer

In addition to your existing intents in the Skills, you must add new intents from which the chat conversation transfer is triggered. 

  1. Create a new intent as described in  Defining intents Open link  and fill out the following fields: 
    1. In Intent Name, specify a name that indicates chatbot transfer.
      For example, switch_to_HR_chatbot
    2. In User example, type a phrase that the end-user might type after which you want to transfer the conversation to the HR chatbot. 
      For example, employee verification letter
    3. Click Add example to add more phrases when you want to transfer to another chatbot. 
      For example, PTO requestchange last name, and so on. 

You have now created an intent so that the Skills is trained to transfer to the HR chatbot when the end-user uses employee verification letter, PTO request, or change last name phrase in the conversation. 



The following image shows an intent and user examples to trigger transfer to the HR chatbot:

               

(For out-of-the-box Skills) To modify Transfer Chatbot Template to enable transfer between chatbots


Warning

To avoid errors, do not delete the dialog nodes after adding them.

  1. Log in to IBM Cloud. 
  2. Navigate to the out-of-the-box IBM Watson AssistantSkills that is provided with BMC Helix Chatbot. 
  3. Click Dialogs and select the BMC - Transfer Chatbot Template node. 
  4. Click Node options and click Duplicate, as shown in the following image:

  5. In Enter node name, type a name for the duplicate node. 
    For example, Transfer to HR chatbot.
  6. Move this new dialog node above the BMC – Search node.
  7. In If assistant recognizes, select #intent and set the appropriate intent that you created earlier
    For example, #switch_to_HR_Chatbot
  8. In the context editor, add values to any one of the following variables:

    VariableValueExample
    $chatbotId

    30-digit chatbot URL ID that is generated in BMC Helix Innovation Studio.

    You can get the ID from https://hostname/com.bmc.dsm.chatbot/index.html#/chatbot/window/30-digit-ID

    ABCDEFGHIJK123LMNOPQRSTUV4XYZ
    $chatbotNameName of the chatbot where you want to transfer. Note: Do not enter the Chatbot Display name.HR Chatbot

    The following image is an example of a context editor:

  9. Save the dialog node.


(For custom Skills) To create a dialog node to enable transfer between chatbots


Warning

To avoid errors, do not delete the dialog nodes after adding them.

  1. Log in to IBM Cloud. 
  2. Navigate to IBM Watson Assistant  Skills that is provided with BMC Helix Chatbot. 
  3. Take backup of the Skills.
  4. Create a new node to enable transfer between chatbots.
    1. Click Dialogs and select the “BMC – Search” node. 
    2. Click Node options and click Add node above.
    3. In Enter Node Name, type a name for the dialog node. 
      For example, Transfer to HR Chatbot
    4. In If assistant recognizes, select #intent and set the appropriate intent that you created earlier
      For example, #switch_to_HR_Chatbot
    5. Open the JSON editor and replace the existing text with the following text:

      {
      
        "output": {
          "text": {
            "values": [
              "${actionResult.output.text}"
            ],
            "selection_policy":
      "sequential"
          },
          "action": {
            "inputMap": {
              "chatId":"$chatId",
              "chatbotId":"$chatbotId",
              "chatbotName":"$chatbotName",
              "mappedResponses": {}
            },
            "outputMap": {
              "result":"${actionResult.output.message}",
              "status":"${actionResult.output.success}"
            },
            "actionTypeName":"checkChatbotExists",
            "waitForActionExecution": true
          }
        },
        "context": {
      "chatbotId":"",
      "chatbotName":"",
          "transferQuestion": "<?input.text ?>"
        }
      }


    6. In Context Editor, provide values to one of the following variables:

      VariableValueExample
      $chatbotId

      30-digit chatbot URL ID that is generated in BMC Helix Innovation Studio.

      You can get the ID from https://hostname/com.bmc.dsm.chatbot/index.html#/chatbot/window/30-digit-ID

      ABCDEFGHIJK123LMNOPQRSTUV4XYZ
      $chatbotNameName of the chatbot where you want to transfer.HR Chatbot
    7. In the Then Assistant should section, select Skip user input
    8. Save the dialog node. 

  5. Create a child node:
    1. Select the new node you created to enable transfer between chatbots. 
      For example, Transfer to HR Chatbot
    2. Click Node options and click Add child node.
    3. In Enter Node Name, type Validation Success
    4. In If the assistant recognizes, type $status="1"
    5. In the JSON editor, replace the existing text with the following text:

      {
        "output": {
          "text": {
            "values": [
              "${actionResult.output}"
            ],
            "selection_policy":
      "sequential"
          },
          "action": {
            "inputMap": {
              "chatId":"$chatId",
              "question":"$transferQuestion",
              "chatbotId":"$chatbotId",
              "chatbotName":"$chatbotName",
              "mappedResponses": {}
            },
            "outputMap": {
              "text":
      "${actionResult.output}"
            },
            "actionTypeName":"transferChat",
            "waitForActionExecution": false
          }
        },
        "context": {}
      }
    6. Save and close the JSON editor.
    7. In Then assistant should section, select Wait for user input
    8. Save these settings. 

 To test the transfer chatbot configuration

After configuring the dialog nodes to enable transfer, you can test the configuration in IBM Watson Assistant.

  1. Log in to IBM Cloud. 
  2. Navigate to the IBM Watson Assistant Skill in which you have configured the dialog node for transfer. 
  3. Click Try it  and type the utterance that triggers the conversation transfer. 
    Verify the following occurrences:
    • The utterance hits the transfer chatbot dialog node. 
    • The chatbot ID and the Chatbot Name is correct. 
    • Use the same utterance in the transferred dialog node and ensure that it does not hit any other transfer dialog node.

To lean more about testing the dialog, see  Improve your Skill Open link  in IBM documentation. 

To disable the list of chatbots to manually transfer a conversation

By default, the chatbots are displayed in a list for the end-users. If you want to disable this list, complete the following steps:

  1. Log in to BMC Helix Innovation Studio and navigate to the Administration tab. 
  2. Select Configure My Server > Chatbots
  3. Click Global Chatbot Settings
  4. Remove the Show dropdown of available chatbots for chatbot switching option. 
  5. Click Save.

Related topics

Submitting service requests and providing feedback through chatbot interaction

Localizing chatbot conversations by using real-time translation


Was this page helpful? Yes No Submitting... Thank you

Comments

  1. Aaditi Lakade

    Hello, 

    Thank you for your query about the following error: 

    ERROR (14058): An attempt to transfer to another chatbot was blocked. Back-to-back chatbot transfer within a single request is not allowed. Occurred when switching chatbot at second time.

    We have added a note on this topic to avoid this scenario.

    Aaditi

     

    Sep 17, 2020 09:30
  2. Pascal Junker

    get the chatbot id: the chatbot id is not included or visible in the URL I think the correct solution is to get the chatbot ID via the {}JSON view.

    Jan 26, 2022 12:20