question

JeremyGreen-4791 avatar image
0 Votes"
JeremyGreen-4791 asked JeremyGreen-4791 answered

QnA Bot generator not connecting to Bot

I have created a Knowledge Base using qnamaker.ai. The knowledge base was successfully set up and I can query that from my desktop using curl.

The "Create Bot" button was pushed and a bot created. However, the Test Bot function in the bot never works.

For example, if I type "Hello" I only see "echo: Hello".

It appears that the knowledge base was not connected to the Bot in the qamaker setup. I can find no configuration in the bot or the service that points to the knowledge base.

I noticed a lot of information online suggesting that there are three "QnA" fields that need to be put into the application configuration, but this information appears out of date.

Has anyone had success at this?

azure-bot-serviceazure-qna-maker
· 10
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@JeremyGreen-4791 The create bot button should open up the Azure portal with the required inputs to create a webapp bot. The same QnAAuthorization key used in curl is pre-populated as QnA Auth Key. Do you see the same key used when this action was performed?

109004-image.png

If the same key is used and still the bot does not respond with any answer from the KB then I suspect the app service of your QnAMaker might need a restart.

If the app service is also fine then I would recommend to download the bot source code from Azure portal and check the appsettings.json file if the QnA details are included in it. Ensure, you include the secrets while downloading the bot source code.

108993-image.png

If this does not point to the right endpoint or key then you can update this and re-publish the bot.

I have created a new bot from QnA and it seems to work as expected.

0 Votes 0 ·
image.png (1.8 KiB)
image.png (16.0 KiB)

This is very helpful thanks and I will try tomorrow.

I do not think that I have seen QnA Auth key. Which screen should it be visible in?

0 Votes 0 ·

This is the screen from Azure portal. Once you click the Create Bot button it should open a new tab with all the settings to create a bot.

0 Votes 0 ·

The parameter appears to be missing. I was expecting QnA Auth in the Create Bot dialog that is presented, but it is not there.

![109199-image.png][1]


0 Votes 0 ·
image.png (57.5 KiB)

For some reason it looks like the options does not include the QnA Auth Key to create a bot. Also, the bot template option is not populated for QnA bot when we click the create bot button. Since it is showing echo bot you are seeing the behavior mentioned.

The URL that opens up should be something like below. You can just replace the values in the placeholders <> and load the page to check if you see the right screen. Please publish your KB prior to this step though.

 https://portal.azure.com/?Microsoft_Azure_BotService_subscriptionId=<your_subscription_id>&Microsoft_Azure_BotService_qnaHostName=<your_qnamaker_resource_name>.azurewebsites.net&Microsoft_Azure_BotService_qnaKbId=<your_KB_ID>&Microsoft_Azure_BotService_csResourceGroupName=<your_resource_group>&Microsoft_Azure_BotService_csAccountName=<your_qnamaker_resource_name>&botsvc.rp=true#create/Microsoft.BotServiceSdkGalleryPackage
0 Votes 0 ·

This appears to be where is goes wrong.

I see this in the click button, it goes to authenticate the account, which is a bit off as it is logged in, then appears to lose the information in the posting.

0 Votes 0 ·

I am not sure why the portal redirect is restricting this for you. I tried another way to load the page. Can you try the same as seen in the image?
You would need to search for "Microsoft.BotServiceSdkGalleryPackage" in the market place offerings. Hit return after you paste the same in the search box.

109394-break-sentence.gif


0 Votes 0 ·
break-sentence.gif (326.6 KiB)

Hi, I tried your suggstion but there are several redirects from the URL and we get back to the problem above. I spoke with a MS support person from the Azure team and they agreed that the screen is not working as it should be. Any chance you can escalate this within MS?

In the meantime, I have been given a Github package to complete the job. I appreciate your help!

0 Votes 0 ·

I am checking this internally with our team. Do you have any other subscription or directory that you could use to try the scenario again with URL?

0 Votes 0 ·

Hi. I tried a fresh subscription, but I am seeing the same behaviour.

0 Votes 0 ·

1 Answer

JeremyGreen-4791 avatar image
0 Votes"
JeremyGreen-4791 answered

I am pleased to report that this is now resolved. The MS Active Directory team have pushed a fix.

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.