Use Power Virtual Agents Chatbot to get Answers From SharePoint!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hey everyone this is Daniel in today's exciting video I'm going to show you how you can use power virtual agent chatbots to get answers from either SharePoint or one drive and no this is not using power automate flow to get it from some SharePoint list or something no this is all happening out of the box the important thing to note is that you can use the PVA chatbot to go ahead and fetch or get the content directly from SharePoint using the signed in user which means we have to go ahead and take care of the meure active directory authentication but we'll take a look at that in a minute what I first want you to see is this demo so here is my chatbot topic and I start a conversation by saying looking for some specific information the next thing it asks is what is a question about so I say new product Innovation and moment I do that it uses the joura of answers to get the answer from SharePoint and first it gives me an overview summary but it also gives me the link and the link takes me to directly where I can find that information in the sh Point side so yes even though this is a fun little chatbot to build the important thing is that you can actually start doing this to go and get existing content from your SharePoint sites so stick around this is very important but first here's my intro [Music] video so let's take a closer look of the topics that has already been created so in my specific chat bot if I just go one step up before there's actually my chat bot called AI bot click on the AI bot I'm in the overview click on topics and the one that I've created is called a SharePoint stuff right so when I click on it uh also it is important to know that when I go back to my topics I'm just in my topics I'm not using any of the plugin actions or anything right directly inside my topic so I go back to my SharePoint stuff um and the beginning of the bot is just like the everyday thing all right you've got triggers in my triggers I've gone and put in triggers which will go ahead and Trigger this topic after that I've enter and added a ask a question the question is directly identified as a user's response saves it directly into a variable and after that this is where the fund begins is in the create generative answers node all right and just for your curiosity if I go and click on the ad note and on the ad note I go ahead and do advanced in the advanced there's something called generative answers that's basically the one that I went and did create generative answers all right so whatever is the answer that I get I'm going to go ahead and save that into a variable and this is how it is by the way right off the bat in this node you can see that the data of sources is coming in from SharePoint on one drive and it automatically does that it's not something that I type that in but here's what it is type that in but here's the information you're looking for in the edit right over here in the generative answers as I scroll down you've got two options is first of all go ahead and search public data so if you go and grab information from some public facing website or a Wikipedia this is where you going put the links to that public website but for our case it is all coming in through the SharePoint site so in the SharePoint site you basically go ahead and put in your url click on plus and it gets saved over here so let me show you the existing site that I have so if I go and click on it double click do a contrl c open up another tab on the browser do a contrl V and I hit enter you will see right off the bat on the URL that this is the root of the site now it's not necessary for me to do that but I just wanted to prove a point to you is that even though I went and did it in the root of the site and you see it over here right this the basically the sharepoint.net I've put it to the root even though I do this when the bot is going to go and generate the answers from here it not only looks at the root S side but all the other subsites as well all right so keep this in mind next thing is we've told the bot that where to go but now I got to tell it how you go ahead and authenticate to that and that is where some work needs to be done and this is something either you could do it or you can go ahead and ask your it specifically your Azure active directory people to go ahead and create this authentication and for that we need to switch gears now and move from the topics to the settings so as I click on the settings and I go to Security on the right side under the security section you click on authentication and on authentication the one option that we are using for this scenario is called manual and yes it says for custom website but that kind of is misleading because this is SharePoint this is the key thing it says ports Azure active directory authentication and remember this is what we need to authenticate the sign in user that's why you got to go for the manual and then you select the box which says requires users to sign in so this is where all the stuff for the configuration comes in all right now I'm not going to walk you through it but but at least I want to show you what all is involved so the first thing that you do is you go and click on this learn more about single sign on or SSO right this is where it starts but you can go and look at the links in the description below because cuz now I want to spend a little bit of time giving you an overview of the configuration that we have to do so you're going to come into your Azure portal you're going to go and click on your Microsoft enter ID which used to be called as Azure active directory click on your app registrations and I'm going to go and show you the one that I already have it's called as SharePoint right over here you see PVA connection with SharePoint so that's the one that I actually use my app registration and over here there's a bunch of stuff that needs to be configured so this is how you want to walk through the flow of the documentation right away here this is the first link configure user authentication with Azure active directory I put this link in the description below this is the first place that you want to start with because it talks about creating a fresh new app and registering that so it's a very step-by-step documentation and I've actually followed it word for word the only change I made over here is because I am located in United States so I actually replaced this Europe from this URL to United States now the documentation says that don't go ahead and do this because it's actually not what I should be doing it says URL that it says using that URL will make the authentication to fail I think this documentation was built specifically if you are located in Europe I am located in United States and therefore this URL actually worked for me so as I continue to scroll down you will see that the next steps are there this is where you go and now create your client secret you go ahead and basically put down some extension period as to when they should go ahead and expire all of this is pretty standard operations procedure to go ahead and register an app in your entry ID so this is not new that's why I'm not spending too much time on this stuff like this has already been done but at least I want to show you how you got to configure that from the power virtual agent standpoint so once you go through this first set of steps you go ahead and grab all of this information which is your client secret ID um going ahead and getting sending out the P you grab that information because it walks you through it and then next you jump over to the authentication section in the authentication section for your power virtual agents once you are there you go ahead and click on the settings go to the manual and that's where you go and start adding in all this information do not do the mistake of selecting the radio button only for teams in fact the documentation states only for teams if you go right now and you take a look at it it says only for teams and power apps because the feature has enhanced you do not want to go and use this all right you want to go and do the manual one because you're setting up this authentication at the user level all right so make sure that you stick to that don't attempt to do this right it's not going to work it's going to keep giving you some errors all right so we go back over here into our documentation and after you've gone ahead and started putting in all of this information make sure for the Scopes section you go ahead and enter in this exact way put it lowercase profile space open ID all put it in this exact same way cuz now that you've done this you got to go back into your Azure or your entra IDs app registration and then configure the API configurations now in the API ones it's very important that you go ahead and set up each and every API and then after you've done it make sure that you grant the admin consent for all of your ones over there CU if you don't do that you're going to get errors and let me show you what that is so if I go now to all my API configurations you can see for each and every one that I've done it they have been granted the status has that check so none of them should be set a pending or any of them should be grade out none of them or you should you should see this check box for each every one of them all right very important point so we go back over here we're going through all these other steps making sure that when you request the API permissions use the delegated permissions don't use the application ones and then you go and start adding all of these different API types all right so I'm just going to scroll down because you see that when you go and get that open ID and profile you had to go Ahad and put that selection directly inside the chatbot that's because you're making that selection over here in its API all right so open API permission um and then again like I said you're going to go back and forth back and forth um and the important thing is that you actually go ahead and set up all of the API con API connections now keep in mind this one thing that I want to share with you it is asking for authentication on behalf of the user for all of your SharePoint files and all of your SharePoint sites therefore that in Microsoft graph you are searching for files. read. all and also sites. read. all which means if you're going to use this creating say some kind of a service account or something um you will have to give that site of full Action level now I know I know some of you are saying Daniel this is not entirely correct I can actually go ahead and do it at a site level there is a way to go and do Azure ad for that there is a way to go ahead and create an AZ there is a way to go and register an app for that I completely agree with you if that is a process in your company to do it at a site level go ahead and do that as well just make sure that each and every site which is going to be leveraged in your chat bot is in that URL so it's going to be some additional work for you um so be prepared for for that but for the sake of this demo and for the sake of what this company had to do they went ahead and put in for all the sites and yes they went ahead and accepted that only these specific chatbot with this specific app registration will allow to do that all right so keep that in mind I had to at least tell you what these other options were for the site level cool all right so finally when you go back now to your chatbot in your chat bot you got to go ahead and put in all of this information so now that you understand that I went and got my client ID from that Azure app register got the secret went and put in the correct token URL and then also put in the correct Scopes all of that was done through the Azure app registration so it's very important that this setting is correct it's very important that you go ah and create your Azure app registration because if any of those steps are missing anything your chatbot is not going to work you may get an error over here or it may just come back and when you do a search for it it's not going to come back with anything so now that you understand this I I want to go and repeat that demo once again and we'll do that so keep that in mind is that this SharePoint site that we went ahead and added directly in our topics let go back and take a look at that again in the SharePoint stuff uh directly in the create generative answers I went and added only the root one see if I click on right right right you don't see anything it's only the root site but the test that I want to do is as follows so right in my chat bot I'm going to actually go and toggle on the track between topics uh and let's just have a good conversation I'm going to go and say hi there right so it automatically will switch over to this topic it's the greetings topic we know that is correct uh and just to make sure I don't make any mistakes I'm going to go and paste this first conversation is looking for some information so it immediately switched over to the SharePoint stuff topic that we created remember the one that has the creative gener remember the one that has the generate creative answers so the question I want to ask the bot is tell me something about this new person hired for this Chief marketing department So based on natural language I'm just going to go and say new Chief marketing person all right I'm just going to put it out that way the bot is going to go and search directly using the generative answers pulls the data straight from SharePoint and comes over here so it's giving me all the links first of all it's saying hey Miriam Graham is the new Chief marketing officer and it's giving me some links so let's start with the first one the first one that it's giving me a re recommendation as three references I click on it um it is still on the root site it's just in the pages of that root site all right which is not bad off the bat on the root side level I got a lot of information about our new Chief marketing officer gives me a b basically a good overview of that next link if I go and click on it another tab opens up and I watch the URL it is actually one sight level deep and that is to prove to you that it just doesn't do a search at the top level just because that's the URL we put in even though we put in the Top Root URL of the site and remember we've got the sites all and the read all level access from the API we are able to go all the sites deep we are able to go all the subsides deep and that's why we are able to go into this one subsite and then let's go and take a look at the last one click on that link it actually opens up another site but check this out it is another subsite completely all right so the one before we had was a subside called the perspective this one over here is subsides called Koso news so I just wanted to drill down that one point is that yes you put that root side but it's all dependent on the access level of that user to go ahead and look at all of these sites over there okay very very important point to think about but overall we successfully got the information we were looking for using the chatbot but getting information directly from the SharePoint site and there you go these are basically all the nodes that we did we don't have to use any power automate we didn't have to go and do any searching create generative answers was the one note that we added and that did all the work for us so hopefully this got you excited and now your wheels are turning on how how you can go ahead and leverage existing SharePoint content and pull that in directly inside power virtual agents chatboard using the create generative answers and now not only can you go ahead and pull in the aspx pages but any of the word documents that you may have or even PDF documents that you may have even all of those can be leveraged so hopefully this give you some information hopefully you're excited and as always keep using power virtual agents hello hello hello so if you like this video go ahead and click on that subscribe button and smash that like button also if you have a few extra seconds can you go and put in a comment either say something nice or give me ideas for my next video and until then see you
Info
Channel: Daniel Christian
Views: 10,457
Rating: undefined out of 5
Keywords: Use Power Virtual Agents Chatbot to get Answers From SharePoint, Daniel Christian Chatbots, generative answers power virtual agents, sharepoint api, power virtual agents tutorial, power virtual agents sharepoint, generative ai, Azure App Registration, NLU Generative Answers From SharePoint, NLU boost node, Power Virtual Agents configuration authentication, Power Virtual Agents advanced tutorial, power virtual agents conversation booster, power virtual agents generative answers
Id: F-XHn6RZ6Eg
Channel Id: undefined
Length: 14min 43sec (883 seconds)
Published: Mon Oct 30 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.