We're trying to build a Microsoft Teams bot using the Composer app to design conversational flows and manage our LUIS application. When testing it in the Emulator and on our company Teams we have to set both the Emulator and the Teams languages to english (US) even if in the app.settings we have specified the default language "it-it" for the LUIS app that is created with the correct culture settings. Otherwise, we obtain this error when getting bot replies:
The given key 'it-IT' was not present in the dictionary.
We tried to re-create the LUIS app setting "it-IT" as the language instead of "it-it" but we obtain the following error during the deploy procedure:
The application version culture must be the same as the application culture.
What we noticed is that teams is looking for culture in format "en-US" or "en-GB" but in the LUIS portal and from the Composer app only all lower case cultures are accepted.
Latest stable
We expected to have coherent culture settings. We couldn't find any information about this in the docs.
The same problem that is affecting Teams is also affecting the Emulator in which we can test our bot only using en-US as locale.
I think this should be a botbuilder issue, sdk should support uppercase culture. (from Teams channel)
@vishwacsena any insight on this? do you think it is OK to move this issue to SDK side?
@luhan2017 what exactly do you believe to be the SDK bug? Can you clarify what in your assessment needs to be fixed on the SDK side?
Any update on this?
@fatherMB sorry for the late response, could you provide more detail on how to reproduce on this? I didn't get a successful repro yet.
@fatherMB I have investigated on this and want to understand more.
For example, in this recognizer, if user says howdy with the activity.locale = en-US, it will be recognized as the Greeting intent.
"recognizer": {
"$kind": "Microsoft.MultiLanguageRecognizer",
"recognizers": {
"en-us": {
"$kind": "Microsoft.RegexRecognizer",
"intents": [
{
"intent": "Greeting",
"pattern": "(?i)howdy"
},
{
"intent": "Goodbye",
"pattern": "(?i)bye"
}
]
}
"": {
"$kind": "Microsoft.RegexRecognizer",
"intents": [
{
"intent": "Greeting",
"pattern": "(?i)salve"
},
{
"intent": "Goodbye",
"pattern": "(?i)vale dicere"
}
]
}
}
}
In the same luis application, you use it-it and it-IT for different versions, that's why the error message showed up, and yes, in luis, we can't use upper case for locale.
did the lubuild really generate the right Multi-language recognizer? The multi locale feature is not officially supported in Composer, I've tried to create a echobot.it-it.lu file, but I didn't successfully get a MultiLanguageRecognizer with it-it locale, could you double check in the botfoldergenerated to see what is your luis recognizer looks like.
We had a fix about 1 or 2 months ago, that make sure the en-us is the default language anyways, so you will not get the "The given key 'it-IT' was not present in the dictionary." error if you try with latest master.
I am not sure whether this reply is helpful, if not, please send me more info about the reproduce steps, I will try to investigate more on this.
I managed to reproduce the issue using also the Bot Emulator application. If I test my bot using the Emulator set with locale en-US everything works fine, if i switch to it-IT it gives this error:

If I set it to it-it to match the locale of our LUIS application it gives the same error regarding the "it-it" key.
@luhan2017 I checked the things you pointed out. The LUIS application locale is always the same for every version (it is impossible for me to create even a brand new app with the it-IT locale). Our bot is not trying to be multi-language. It has to handle only italian language conversations and i expect clients to connect to it using the proper locale, and not en-US. This issue is causing our users to switch their Teams language settings to american english as a workaround.
These are the LUIS settings, in particular the locale part:

And the LUIS app settings:

Hope this helps.
@fathorMB multi-language feature is not officially supported by composer yet. we will enabled the multi-language feature in R10 time frame, which should fix this issue. will let you know when the feature is merged, thanks for your patience.
@luhan2017 do you have a tracking item for the multi-language support? And what does multi-language mean for you? Is it just changing the bot language to something different, than en-us or having a bot with multiple languages?
Our customer's bot has got the requirement that is has to be in german. When is R10 due? I believe I could build the Composer myself as soon as the PR is merged into master, if we can't wait for R10...
@eluchsinger, @fathorMB , the multi-language feature is already merged in to main branch, could you have a try and let us know if there is any issues in your scenario?