Introduction:

Language Understanding service (LUIS) allows our any application to understand what a person wants in their own words. LUIS can integrate to Windows, Web, Bot and mobile application, which can consume Json response to the application. LUIS uses machine learning to allow developers to build applications that can receive user input in natural language and extract meaning from the user input.

Building an app is a free and doesn't require an Azure subscription, in this article, I will show how to build a new app in the LUIS portal.



Once the LUIS app is published, a client application sends utterances (text) to the LUIS natural language processing endpoint API and receives the results as JSON responses. First you create the basic parts of an app, intents, and entities. Then you test the app by providing a sample user utterance in the interactive test panel to get the predicted intent.


Create LUIS App:

Step 1: 

Navigate to LUIS Portal in a browser and sign in. if you are trying to create first time signing in, you need to create free LUIS account.

Step 2: 

Click on “Create New App” from portal menu options.



Step 3: 

Provide name, culture and description in the following information into the new app screen.

Name - provide the relevant to your application and Unique LUIS app name

Culture – Luis will support multiple language, now we will select as English Language

Description - Provide the Description of app and its optional field



Once completed, Click on Done button and Select “Build” menu from main menu.


Create Intents:

Intent is an action the user wants to perform. Natural language is extremely flexible. in fact, different languages and cultures make them less or more flexible. But what is the user’s "intention?" It’s the goal the user is trying to achieve. Maybe they want to turn the lights on. Maybe they want to schedule a calendar appointment. Maybe they want to Send Email. Whatever the intent may be, the user can express themselves in a multitude of ways, but it always translates to one intent. LUIS understands utterances and converts them to one or more intents that you specify in our LUIS application. There are two type intent

New Intent – you can create custom intent-based user needs

Add prebuild domain Intent - you can use prebuilt intents from one of the prebuilt domains.

Select Intents > Click on New intent or Add prebuilt domain intent 


Prebuilt domain intents are parts of prebuilt domains, you can select inbuild category and intents from the list, here, we will select sending email and send email prebuilt domain intents 


Create Entities:

When the user issues a command as an utterance, that utterance is converted into an intent. But hidden inside that utterance is important data that’s needed to complete the action. For example, "turn the lights off" represents an action called "off;" what entity is it working on? It’s working on lights. You need to extract a single entity out of this utterance.

Select Entities > Add the Prebuild domain entity 


LUIS comes with a number of prebuilt domain models with prebuilt entities. Or you can quite easily create a new custom domain model with custom entities. Here we are creating Prebuilt domain entry 


In order to train the model, you’ll see a Train button on the top right-hand corner


Now you can start publish our LUIS application



While publish application, will be available multiple environment, let we start “Production” environment and publish


after publish its available in publicly the end point URL




Here you can view your publish settings, as well as your LUIS App ID and Password. You will need these to access your LUIS app from your client applications. Please note that you can also type in queries directly to your production endpoint, and you’ll get a JSON response from LUIS




When your model is trained and up-to-date, you can then open the test panel and provide some utterances to your LUIS model



You can copy paste the URL highlighted in key Endpoint setting screen and under the endpoint column (note that the app ID and keys are removed for this image) into an internet browser, and type the query – “Please email to Suthahar”. Below is the full JSON response for the query


Summary

In this article, you learned about how to create Natural Language Understanding app with LUIS .If you have any questions/ feedback/ issues, please write them in the comment box.

Featured Post

Improving C# Performance by Using AsSpan and Avoiding Substring

During development and everyday use, Substring is often the go-to choice for string manipulation. However, there are cases where Substring c...

MSDEVBUILD - English Channel

MSDEVBUILD - Tamil Channel

Popular Posts