Botframework-solutions: Virtual assistant dialogs need warmup

Created on 5 Jan 2021  路  9Comments  路  Source: microsoft/botframework-solutions

What project is affected?

Latest VA sample and skills

What language is this in?

C#

What happens?

The VA invocation phrase "sample dialog" does not work from OnBeginDialogAsync. It goes to generic invocation instead of skill invocation.

What are the steps to reproduce this issue?

  1. Deploy sample VA
  2. Deploy sample skill
  3. Connect skill to the VA
  4. Deploy the bots to azure and register VA bot in teams
  5. In Teams channel and start a new conversation; "Hi @SampleVA" and get a generic response from VA. Now "@SampleVA sample dialog" invokes sample skills. This is expected.
  6. In Teams channel start a new conversation; "@SampleVA sample dialog". This invokes generic response instead of routing to skills
  7. Reason for above is, in MainDialog.cs of sample VA, the new conversation is not handled correctly in InterruptDialogAsync (innerDc.ActiveDialog is null and other logic is not correct so it routes to generic response)

What were you expecting to happen?

Teams channel new conversation message "@SampleVA sample dialog" is routed to skills. Both step 5 and 6 should produce same response for "@SampleVA sample dialog"

Can you share any logs, error output, etc.?

Above steps should give enough info.

Any screenshots or additional context?

Kobuk Bug

Most helpful comment

@VictorGrycuk We are glad to hear the workaround fixed it. We currently do not have the staffing for the bug fix. Closing it for now.

All 9 comments

Hi @Batta32, can you review this one?

Thanks

Sure @gabog ! We will be reviewing this issue trying to reproduce the problem. As soon as we have any update we will back here 馃槉.

Hi @ipraveenMS, sorry for the delay. We are currently working on this issue, so this week we will let you know the updates 馃槉.

@ipraveenMS - We reproduced the issue and sending the skill utterance before or during the onboarding dialog will not activate the Skill. We checked why this is happening, and we believe this is by design.

The steps we took were the following:

  1. Build and deploy the C# Virtual Assistant sample
  2. Build and deploy the C# Skill sample
  3. Connect both using the Botskills tool
  4. Enable Microsoft Teams channel
  5. Add the Virtual Assistant bot to Teams
  6. Send run sample dialog as first message
  7. The skill will not be triggered

Following the Activity Handling document:

  1. When the first message is sent, the method OnBeginDialogAsync is called.
  2. Then it will call InterruptDialogAsync to check if the conversation was interrupted

    1. It is OK for dialog to be null, as no dialog has started yet

    2. Also, since this method will return false because the current dialog is not a skill (so it won't ask the user if they wish to switch skill), and the utterance is not a General intent.

  3. Since it was not interrupted, it will start with the first step of the defined WaterfallStep, which is the OnboardingStepAsync method.
  4. It is not that until it reach the RouteStepAsync method step of the waterfall that it will check if the intent is a skill utterance, and start the skill if it is.

@ipraveenMS - We found a workaround. It consists on extracting the logic that checks if the activity contains a skill utterance, and call it if it does, to its own method. Then that method can be called in earlier steps, such as before the OnBoardingStep or even in the InterruptDialog method.

This would require analyzing which should have a higher priority, if the onboarding process of the dialog, or the execution of the skill intent.

@VictorGrycuk @gabog This is a regression from previous behavior. We have BF from the versions where this works (VA and skill are in the same process, not different micro services) . So its not by design, its a bug.

Regarding the workaround, yes this came to my mind. But my ask here for you to address this as a bug and actually fix it in the code base which is much preferable rather than doing some one off fixes to my code which creates issues every time I sync (when ever you release new BF version with VA code changes).

Hi @ipraveenMS, we will be re analysing this.
We will let you know as soon as we have an update.

Thats great, let us know when this is fixed. For now I have incorporated the workaround in my code.

@VictorGrycuk We are glad to hear the workaround fixed it. We currently do not have the staffing for the bug fix. Closing it for now.

Was this page helpful?
0 / 5 - 0 ratings