LUIS0.PNG

You can use the Microsoft LUIS NLU Connector to connect to Microsoft LUIS
and use the language understanding results from this service to power the NLU
of agents within Cognigy.AI. This guide covers the necessary prerequisites for setting up the LUIS NLU Connector, and how to connect a LUIS app to a LUIS NLU Connector in Cognigy.AI.

Requirements

You'll need the following credential to successfully connect to a Microsoft LUIS service from Cognigy.AI:

    • Location (e.g. westus2)
    • Subscription Key
    • App ID

Setup

This section describes the necessary steps for setting up a LUIS NLU Connector.

1. Create and publish a Microsoft LUIS app

🔗 In Microsoft LUIS

In order to use the LUIS NLU Connector, a working LUIS app is required. To setup a new app, refer to the guides from the Microsoft LUIS Documentation listed below:

Publishing in production

Note that it is required to publish your Microsoft LUIS app in production in order for the NLU Connector to work.

2. Retrieve the Authentication Parameters

🔗 In Microsoft LUIS

In order for the NLU Connector to connect to the LUIS app, it needs an authentication URL, the details for which can be found in the LUIS app.

In the LUIS app, navigate to `Manage > Azure Resources` to view the prediction resource parameters. Retrieve the following parameters:

  • Location (e.g. westus2)
  • Subscription Key (Primary or Secondary)

AR1.PNG

Navigate to `Manage > Settings` to view the retrieve the following parameter:

  • App ID

AR2.PNG

These three credentials are required to build the Authentication URL that will be used by Cognigy.AI to call you LUIS app.

LUIS V3 Prediction API

Please note that Cognigy.AI currently only supports the LUIS v2 Prediction API by default. To use the v3 api, an NLU transformer is required to adjust the response format.

If the prediction resource parameters are not show in the Azure Resources menu (available initially with a trial account), you will need to create a prediction resource, in line with your Microsoft subscription, that enables communication to Microsoft LUIS from a third party service. Find out how to add a prediction resource in the Microsoft Documentation

3. Connect the MS LUIS NLU Connector

🔗 In Cognigy.AI

The last step is to create and configure a LUIS NLU Connector on the Cognigy.AI platform.

In Cognigy.AI, navigate to the NLU connectors menu found under the Build sub-menu in the resources panel. Create a new NLU Connector of type LUIS

NLUConnectors_Menu.PNG

The NLU connector settings will be opened automatically (you can open the settings again by clicking on the NLU connector). 

Paste the below URL into the `Authentication URL` field in the `LUIS Settings`of the NLU Connector and substitute the parameters retrieved in the previous step.

https://{location}.api.cognitive.microsoft.com/luis/v2.0/apps/{appId}?subscription-key={subscriptionKey}&q=

settingsLUIS.PNG

4. Test your NLU Connector

🔗 In Cognigy.AI

Open the interaction panel from the top right of the interface. Select settings, then select the LUIS NLU connector you just created from the NLU Connector dropdown menu. Additionally, enable Expert Mode to get a summary of the intent mapping printed to the chat window.

InteractionPanelNLU.PNG

Now select the chat tab and type a message to your bot that was one of the example sentences you used for intent creation in the LUIS app. If the connection is successful, you will see an orange box showing the name of the LUIS intent that you configured in your LUIS app.

ExpertMode_Dialogflow.PNG

Congratulations, you have successfully connected Microsoft LUIS as the NLU service for Cognigy.AI!

Deploying your External NLU

Once you have activated an NLU connector, it will become available for use with Endpoints and the Interaction Panel. Visit the Cognigy.AI External NLU documentation page to find out how to deploy your external NLU within the platform.


Comments

0 comments

Please sign in to leave a comment.

Was this article helpful?
0 out of 0 found this helpful