Skip to content

makenasandra/Building-Smarter-Solutions-Using-Azure-And-Cognitive-Services

 
 

Repository files navigation

Building Smarter Solutions Using Azure And Cognitive Services

There's a lot of discussion going on around Artificial Intelligence, and for good reason. AI and Cognitive Services are getting more powerful all the time, and it can be confronting to see all these developments. But how can we leverage this power in our own solutions, using it for making the life of our users and customers easier?

In this session, you will see learn we can get data from the real world, and use this to drive our business, and all this in a serverless manner. Thanks to Microsoft Cognitive Services it's easy to integrate and work with speech, text, images and videos into our processes. Come and learn how to use this to your own advantage, driving your business forward.

Preparations

  • Update all values in the parameters file according to your own environment.
  • Make sure to update the organization in the commonDataService parameter according to your CRM organization.
  • Make sure the Entities / Tables and their corresponding Fields / Columns specified in the commonDataService parameter are created in your Data Verse environment.
  • Make sure at least one Ship entry is created with a shipname set to Somtrans LNG.

Deployment

Post-deployment

LUIS

  • Create LUIS authoring application in the LUIS portal.
  • Create a new LUIS authoring resource with, name set to luis-building-smarter-solutions-using-cognitive-services, via the authoring resources blade.
  • Switch to the newly created authoring resource and import the LUIS definition from luis-building-smarter-solutions-using-cognitive-services.json.
  • Train the model and publish it to the production slot when training has finished.
  • Update the configuration parameter LuisAppId of the bot application settings with the identifier found on Manage page of the LUIS application in the Luis portal.
  • Update the configuration parameter LuisAPIKey of the bot with the API key which can be found in the Azure portal.

Bot

  • Clone the bot repository and make sure you can build and run it.
  • Add an appsettings.json file with the content found below.
  • Update the configuration as necessary.
  • Run the bot locally using the Bot Framework Emulator.
{
  "MicrosoftAppId": "",
  "MicrosoftAppPassword": "",
  "LuisAppId": "00000000-0000-0000-0000-000000000000",
  "LuisAPIKey": "<your-luis-api-key>",
  "LuisAPIHostName": "<your-luis-region>.api.cognitive.microsoft.com",
  "ApiManagementEndpoint": "https://<your-apim-instance-name>.azure-api.net",
  "ApiManagementSubscriptionKey": "<your-api-management-subscription-key>",
  "ApiManagementCreateVisitorPath": "/visitors/create",
  "BlobConnectionString": "DefaultEndpointsProtocol=https;AccountName=<your-storage-account-name>;AccountKey=<your-storage-account-key>;EndpointSuffix=core.windows.net",
  "BlobContainerVisitorPictures": "visitorpictures"
}

RTT Cockpit

  • Clone the RTTCockpit repository and make sure you can build and run it.
  • Add an App.config file with the content found below.
  • Update the configuration as necessary.
<?xml version="1.0"?>
<configuration>
  <appSettings>
    <add key="ServiceBusConnectionString" value="Endpoint=sb://<your-service-bus-namespace>.servicebus.windows.net/;SharedAccessKeyName=RootManageSharedAccessKey;SharedAccessKey=<your-shared-access-key>" />
    <add key="QueueGateCamera" value="gate-camera" />
    <add key="QueueCarCamera" value="car-camera" />
    <add key="QueueDepartureCamera" value="departure-camera" />
  </appSettings>
</configuration>

VIsual Studio Code

  • Create a .vscode/settings.json as outlined below.
  • Update faceApiSubscriptionKey in the settings file.
  • Update formRecognizerApiSubscriptionKey in the settings file.
{
    "rest-client.environmentVariables": {
        "$shared": {
            "faceApiSubscriptionKey": "<your-api-subscription-key>",
            "formRecognizerApiSubscriptionKey": "<your-api-subscription-key>"
        }
    }
}

Train Form Recognizer API

Face API

  • Execute the call in file faces.rest to create a person group.

Authorize API Connections

  • Authorize the following connections, using the Edit API connection blade of the corresponding resource in the Azure portal.
    • Common Data Service
    • Office 365 Outlook

Update Logic App actions

Example utterances

  • The Somtrans LNG would like to register Eldert Grootenboer as a visitor to do repairs by tomorrow afternoon. Their email address is eldert@eldert.net to contact them on.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 97.6%
  • HTML 1.4%
  • Other 1.0%