Can Luis be used in Bots designed on platform other than MSFT Bot Framework - botframework

Can Luis be used in Bots designed on a platform other than MSFT Bot Framework like chatfeul.

After training a LUIS model, you get an endpoint which is a REST service that can be called. You can then pass parameters to this, modify it according to need and get a JSON response.
You can read more about connecting an API to chatfuel here

Related

How to add a Prediction Resource to LUIS app programmatically

I am using C# SDK to create the LUIS apps with required Intents, Utterances and Entities, and then training and Publishing the apps using an Authoring key created in Azure portal. After this, I use the REST Prediction endpoint for Intent matching, and till now I used the free Starter Prediction Key. After a month since the Starter key gets expired, I created a Cognitive service in Azure to be used as the Prediction resource. Now, how to add this new Prediction resource(Cognitive service) to my LUIS apps via SDK or REST? I am able to do so from LUIS Portal though, but don't want manual intervention.
Once you create the prediction endpoint resource, the resource should be only used for endpoint prediction queries and not for authoring changes to the app. If you want to add the prediction resource to your app by not going through the portal and automate the assignment of the resource to a LUIS app for purposes like CI/CD pipeline, then you can follow the steps below:
Get an Azure Resource Manager token from this website. This token does expire so use it immediately. The request returns an Azure Resource Manager token.
Use the token to request the LUIS runtime resources across subscriptions, from the Get LUIS azure accounts API, which your user account has access to.
This POST API requires the following settings:
This API returns an array of JSON objects of your LUIS subscriptions including subscription ID, resource group, and resource name, returned as account name. Find the one item in the array that is the LUIS resource to assign to the LUIS app.
Assign the token to the LUIS resource with the Assign a LUIS azure accounts to an application API.
This POST API requires the following settings:
When this API is successful, it returns a 201 - created status.
Hope this helps.
Thanks, accepted. The only issue being, since I am doing every thing using SDK, it takes a lot of API calls to get things done. I mean to solve this, first I am generating a Token and then calling this API. A simple add default "Prediction Resource" for all apps on LUIS portal would have helped a lot. Anyways, thanks for this answer. – user3868541 Feb 3 at 9:45
Agreed that an Add default Prediction Resource would have made everything much better. I'm still not sure how to do this programmatically. I'm trying to do it in my service using the SDK

Can we develop a functional or process bot using azure service

I'm looking for a solution where my bot can understand users request(may be with LUIS this can be achieved) and verifies/validates the user/requirement with master data. If all good, then connect to my native database(Siebel CRM via API) to perform the defined action and log a reference ticket(via API) and finally send an email to user using outlook. Is this achievable using azure service?
Yes, the Bot Framework can do all of those things:
my bot can understand users request
LUIS is perfect for this.
verifies/validates the user/requirement with master data
All of this can be done within Waterfall dialogs or Prompts. You can either store the master data in the bot code, or query it from an external source and have the bot validate against it.
Here's a good sample for prompts and validation.
connect to my native database(Siebel CRM via API) to perform the defined action and log a reference ticket(via API)
The bot runs on C#/Node, so anything (including calling your APIs) that you can do in C#/Node, you can do in your bot.
send an email to user using outlook
Bot Framework has a specific Email Channel for this or you can use the Graph API.
Recommended Resources
Docs and QuickStarts
Samples Repo
Reference Docs: C# / TypeScript
LUIS Docs

How to get Microsoft Graph access token using email id in the skype for business bot to add an event to Calendar

In Skype for Business Bot , User is pre-authenticated, need to get Microsoft graph access token , in order to perform Microsoft Graph operations (such as adding events to calendar) in programmatic way..
Please suggest how Microsoft Graph Apis can be integrated with Azure Bot for Skype for business channel.
We want Skype for Business bot to book the meeting just like described here
But instead of Teams need to use Skype for Business. but basically this code line will ask user to explicitly in this code sample
"await context.Forward(new AzureAuthDialog("
There is another sample that need Adminconsent to update the calendar of specific user
Swati
You cannot reuse anything from the pre-authentication. Like any other channel, you have to go through a specific authentication phase.
You have a great sample on the official repository to do this, here: https://github.com/Microsoft/BotBuilder-Samples/tree/master/samples/csharp_dotnetcore/24.bot-authentication-msgraph

Dialogflow Webhook C# integration

What is the Dialogflow webhook format? I want to capture the data in an MVC controller and then respond to the webhook whilst maintaining context. How do I do this in C# with the Dialogflow v2 client library? I haven't found any examples to follow in this language and am unsure how to capture the data.
You can read more about Dialogflow webhook format here. Regarding the Dialoglow v2 client library, it is specifically stating that you don't need to use it and can answer in JSON instead using JObject.
If you want to use Protobuf to lower the overhead and save some traffic you will have to use utilities from idiomatic cloud libraries described in the previous link.
The "Dialogflow V2 client library" is for people who are writing clients that send requests to Dialogflow. Dialogflow calls this a "Detect Intent Request", since you're sending a text string (or audio stream) to Dialogflow and it will determine and process the Intent.
If you're interested in building a Fulfillment webhook that is called when an Intent is matched, then you want to look at the Dialogflow Fulfillment API, which is different. There is no supported library for C# yet, but you can parse and return the JSON. The JSON for V1 and V2 are slightly different (mostly in the names of the fields used, but also occasionally in what the values should be).
You can see the fields for the JSON as well as several examples of the request and response formats. There was also an article on Medium recently posted by a Google Developer Relations member discussing using C# for fulfillment in Dialogflow.

LUIS Dispatch Bot sdk V3 support?

Is it possible to create LUIS Dispatch for existing V3 Bot ? We have v3 bot that's in production and we have gone so far now so its difficult to switch over v4 Bot. However, there are awesome capabilities like LUIS dispatch tool that we would like to leverage.
Ref:-
https://learn.microsoft.com/en-us/azure/bot-service/bot-builder-tutorial-dispatch?view=azure-bot-service-4.0&tabs=jsaddref%2Cjsbotconfig#integrate-multiple-luis-apps-and-qna-services-with-the-dispatch-tool
Given the fact that the source code is available for the LUIS components and the provided examples, I think you can use this tool on v3 bot after some modifications.
It looks like the dispatch tool is only preparing a custom LUIS app that you will query from your bot, so nothing really linked to v4 of bot builder.

Resources