Create your first LUIS app
This article shows you how to create a LUIS app that uses the
HomeAutomation prebuilt domain. The prebuilt domain provides intents and entities for a home automation system for turning lights and appliances on and off. When you're finished, you'll have a LUIS endpoint running in the cloud.
Create a new app
You can create and manage your applications on My Apps page of LUIS.
Click Create new app.
In the dialog box, name your application "Home Automation".
Choose your application culture (for this Home Automation app, choose English), and then click Done.
The culture cannot be changed once the application is created.
LUIS creates the Home Automation app.
Add prebuilt domain
Click on Prebuilt domains in the left-side navigation pane. Then search for "Home". Click on Add domain.
When the domain is successfully added, the prebuilt domain box displays a Remove domain button.
Intents and entities
Click on Intents in the left-side navigation pane to review the HomeAutomation domain intents.
Each intent has sample utterances.
None is an intent provided by all LUIS apps. You use it to handle utterances that don't correspond to functionality your app provides.
Click on the HomeAutomation.TurnOff intent. You can see that the intent contains a list of utterances that are labeled with entities.
Train your app
Click on Train in the top navigation.
Test your app
Once you've trained your app, you can test it. Click Test in the top navigation. Type a test utterance like "Turn off the lights" into the Interactive Testing pane, and press Enter.
Turn off the lights
Check that the top scoring intent corresponds to the intent you expected for each test utterance.
In this example, "Turn off the lights" is correctly identified as the top scoring intent of "HomeAutomation.TurnOff."
Click Test again to collapse the test pane.
Publish your app
Select Publish from the top navigation.
Click Publish to production slot.
The green notification bar at the top indicates the app successfully published.
After you've successfully published, you can use the endpoint URL displayed in the Publish app page.
Use your app
You can test your published endpoint in a browser using the generated URL. Open this URL in your browser, set the URL parameter "&q" to your test query. For example, add
turn off the living room light to the end of your URL, and then press Enter. The browser displays the JSON response of your HTTP endpoint.
You can call the endpoint from code: