Building Applications with LUIS Sam Nasr, MCSA, MVP NIS Technologies October 26, 2017
Housekeeping Bathrooms Forum for learning: feel free to ask questions Cell phones on vibrate please
Introduction Software developer since 1995 Sam Nasr (snasr@nistechnologies.com) Software developer since 1995 Sr. Software Engineer/Instructor (NIS Technologies) Certifications: MCSA, MCAD, MCT, MCTS President - Cleveland C#/VB.Net User Group President - .Net Study Group Author for Visual Studio Magazine (since 2012) Microsoft Most Valuable Professional (since 2013)
Computer Input
LUIS LUIS: Language Understanding Intelligence Service Built on interactive machine learning (Microsoft Research). Uses language model, training examples to parse natural spoken language LUIS app is published as a REST API Endpoint Accepts text string (user input) Returns only the parts a developer needs to interact with users.
Language Understanding Intelligence Service
Language Models Language models are specific to your LUIS apps. Form the basis of what users mean Core parts of a language model: Add intents: “BuyCar” Add utterances: “I want to buy a Mustang” Add entities: Mustang, Explorer, etc.
Results { "query": "I want to buy a Mustang", "topScoringIntent": { "intent": "BuyCar", "score": 0.9999995 }, "intents": [ } ], "entities": [ "entity": "mustang", "type": "car", "startIndex": 16, "endIndex": 22, "score": 0.9716398 ]
Machine Learning “Machine Learning” (1997) by Tom Mitchell : “A computer program is said to learn to perform a task T from experience E, if its performance at task T, as measured by a performance metric P, improves with experience E over time.”
Building a LUIS App Create Azure account, obtain keys Setup app in http://luis.ai Add intents: “BuyCar” Add utterances: “I want to buy a Mustang” Add entities: Mustang, Explorer, etc. ($car) Train and test Publish
Demo
Entity Types Simple: generic, describes a single noun. Hierarchical: category/members, or type/subtypes (i.e. GT, Cobra, Mach1) Composite: entities forming parts of a whole. (i.e. “Mustang GT Convertible”) List: fixed list of synonyms or related words.
Languages
Prebuilt Models
Manage LUIS Apps Monitor your App using the Dashboard Manage Keys Usage Intents targeted Manage Keys Batch Testing
Batch Testing Array of utterances in JSON format Entity indices should be supplied using character counts. Entities are not allowed to start or end in the middle of words. A maximum of 1000 utterances are allowed in each file.
Gotcha’s Must have an Azure subscription prior to logging into luis.ai, else top nav bar will be missing. Culture cannot be changed once the application is created. Delay in dashboard metric refreshes For Bing Speech API, use a WebRTC compatible browser. 1. To use Microsoft Cognitive Service APIs, you first need to create a Cognitive Services API account in the Azure portal.
Recap What is LUIS? How do we create an app? What are some gotcha’s?
References Learn about Language Understanding Intelligent Service (LUIS) https://docs.microsoft.com/en-us/azure/cognitive-services/luis/home Create your first LUIS app in ten minutes https://docs.microsoft.com/en-us/azure/cognitive-services/luis/luis-get-started-create-app Localization support in LUIS apps (Language Support) https://docs.microsoft.com/en-us/azure/cognitive-services/luis/luis-concept-language-support Use prebuilt domains in LUIS apps https://docs.microsoft.com/en-us/azure/cognitive-services/luis/luis-how-to-use-prebuilt-domains
Contact Info snasr@nistechnologies.com @SamNasr http://www.linkedin.com/in/samsnasr Thank you for attending!