Example #1
0
        private async Task <DialogTurnResult> ManageIntentions(WaterfallStepContext stepContext, Microsoft.Bot.Builder.RecognizerResult luisResult, CancellationToken cancellationToken)
        {
            var topIntent = luisResult.GetTopScoringIntent();

            switch (topIntent.intent)
            {
            case "Saudar":
                await IntentSaudar(stepContext, luisResult, cancellationToken);

                break;

            case "Agradecer":
                await IntentAgradecer(stepContext, luisResult, cancellationToken);

                break;

            case "Despedir":
                await IntentDespedir(stepContext, luisResult, cancellationToken);

                break;

            case "VerContato":
                await IntentVerContato(stepContext, luisResult, cancellationToken);

                break;

            case "VerOpcoes":
                await IntentVerOpcoes(stepContext, luisResult, cancellationToken);

                break;

            case "Avaliar":
                return(await IntentAvaliar(stepContext, luisResult, cancellationToken));

            case "CriarConsulta":
                return(await IntentCriarConsulta(stepContext, luisResult, cancellationToken));

            case "None":
                await IntentNone(stepContext, luisResult, cancellationToken);

                break;

            default:
                break;
            }
            return(await stepContext.NextAsync(cancellationToken));
        }
Example #2
0
        private async Task <DialogTurnResult> ManageIntentions(WaterfallStepContext stepContext, Microsoft.Bot.Builder.RecognizerResult luisResult, CancellationToken cancellationToken)
        {
            var TopIntent = luisResult.GetTopScoringIntent();

            switch (TopIntent.intent)
            {
            case "Saludar":
                await IntentSaludar(stepContext, luisResult, cancellationToken);

                break;

            /*case "Agradecer":
             *  await IntentAgradecer(stepContext, luisResult, cancellationToken);
             *  break;
             * case "Despedir":
             *  await IntentDespedir(stepContext, luisResult, cancellationToken);
             *  break;*/
            case "MatrĂ­culas":
                await IntentMatriculas(stepContext, luisResult, cancellationToken);

                break;

            case "Video":
                await IntentVideo(stepContext, luisResult, cancellationToken);

                break;

            case "Perfil":
                await IntentPerfil(stepContext, luisResult, cancellationToken);

                break;

            case "Calificacciones":
                await IntentCalificaciones(stepContext, luisResult, cancellationToken);

                break;

            case "BuscarCurso":
                await IntentBuscarCurso(stepContext, luisResult, cancellationToken);

                break;

            case "Confirmacion":
                await Confirmacion(stepContext, luisResult, cancellationToken);

                break;

            case "VerOpciones":
                await IntentVerOpciones(stepContext, luisResult, cancellationToken);

                break;

            case "VerCentroContacto":
                await IntentVerCentroContacto(stepContext, luisResult, cancellationToken);

                break;

            case "Calificar":
                return(await IntentCalificar(stepContext, luisResult, cancellationToken));

            case "None":
                await IntentNone(stepContext, luisResult, cancellationToken);

                break;

            default:
                break;
            }
            return(await stepContext.NextAsync(cancellationToken : cancellationToken));
        }