Skibisky
Skibisky

Reputation: 133

Luis not returning the same details to bot

I am trying to make a bot using Azure Language Understanding and it was going along smoothly until I tried to get entity recognition working.

Initially I tried making many hierarchical entities in the hope Luis would eventually be able to pick them out, but after looking around, a number of the examples pointed to using a smaller number of entities.

It also appeared that Luis was better at picking words in utterances based on location rather than text, so I now have ~4 intents and ~entities. with about 20 utterances in each.

When I submit new utterances to the API, it only typically returns 1 of 2 intents and no entities. Ever.

But when I look at the Luis.ai dashboard, it shows different Intent scores and actually tags words as entities.

I am invoking the API with webClient.DownloadString("https://australiaeast.api.cognitive.microsoft.com/...") and deserializing the JSON into Microsoft.Bot.Builder.Luis.Models.LuisResult

Returned values vs Values in Luis

Do I have a wrong setting?
Do I need to train Luis more?
Am I calling the endpoint wrong?

What steps should I take to try and get the entities returned?

Upvotes: 1

Views: 866

Answers (2)

Ashwin Kumar
Ashwin Kumar

Reputation: 1248

You need to Publish your LUIS app model every time after making changes in the model and training them.

When you train the model, the updated model resides just within the portal and is not available to the entire world to be accessible. Publishing the model, makes the changes available to be accessible in the published slot.

One way to check if LUIS responds as expected in published model also, is to make use of the Test feature in LUIS.

enter image description here

Clicking on Compare with published opens up another blade which shows the response of the utterance in the published model. (Can select for production as well staging slot).

enter image description here

Upvotes: 2

Jyo Fanidam
Jyo Fanidam

Reputation: 1230

The region in which you publish your LUIS app corresponds to the region or location you specify in the Azure portal when you create an Azure LUIS endpoint key. To publish to the Australian regions, you create LUIS apps at https://au.luis.ai only. If you attempt to publish anywhere else using a key in the Australian region, LUIS displays a warning message. Instead, use https://au.luis.ai. LUIS apps created at https://au.luis.ai don't automatically migrate to other regions. You need to export and then import the LUIS app in order to migrate it.

LUIS uses active learning for the prediction of the utterances. Looks like you have little confusion to differentiate between the label entities and the LUIS prediction (aligned intent). You can label the entities and train them to improve the performance of the app as mentioned here.

LUIS guides the developer through the improvement process through the "Suggest" feature that suggests utterances to label from the utterances sent to the http endpoint of the application. These utterances are suggested per intent or entity depending on which models the developer is willing to improve. You can decide which intents or entities require improvement by either looking at the dashboard in the LUIS portal that tracks performance of each model through interactive testing or through the batch testing to measure the models' quality on a test set or both. You should keep going in iterations until satisfied with the quality of your models. Hope this helps!!

Upvotes: 0

Related Questions