示例#1
0
        public InitialServiceDialog(LuisSetup luisRecognizer, ILogger <InitialServiceDialog> logger, UserState userState, NIFPermissionDialog nIFPermission, IsNotClientDialog isNot, NoUnderstandDialog noUnderstand, GoodbyeDialog goodbye)
            : base(nameof(InitialServiceDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            //AddDialog(new MainDialog());
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(nIFPermission);
            AddDialog(isNot);
            AddDialog(noUnderstand);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                AreYouClientAsync,
                IfIsAsync,
                IfIsRetryAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#2
0
        public WantMoreDialog(LuisSetup luisRecognizer, ILogger <WantMoreDialog> logger, UserState userState, InfoSendDialog infoSend, NoUnderstandDialog noUnderstandDialog, GoodbyeDialog goodbye)
            : base(nameof(WantMoreDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(infoSend);
            AddDialog(noUnderstandDialog);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                MoreAsync,
                CheckMoreAsync,
                RetryCheckMoreAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#3
0
        public InfoSendDialog(LuisSetup luisRecognizer, ILogger <InfoSendDialog> logger, UserState userState, NoUnderstandDialog noUnderstand, SendContactDialog sendContact, GoodbyeDialog goodbye)
            : base(nameof(InfoSendDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            //AddDialog(new MainDialog());
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noUnderstand);
            AddDialog(sendContact);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                WhereAsync,
                PhoneOrEmailAsync,
                RetryPhoneOrEmailAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#4
0
        public GetHelpDialog(LuisSetup luisRecognizer, ILogger <GetHelpDialog> logger, UserState userState, NoUnderstandDialog noUnderstand, GiveOptionsDialog giveOptions, GoodbyeDialog goodbye, IHttpClientFactory httpClient, IConfiguration configuration, NoPermissionDialog noPermission)
            : base(nameof(GetHelpDialog))
        {
            _recognizer        = luisRecognizer;
            _userState         = userState;
            _configuration     = configuration;
            _httpClientFactory = httpClient;
            Logger             = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noUnderstand);
            AddDialog(giveOptions);
            AddDialog(goodbye);
            AddDialog(noPermission);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                AskHelpAsync,
                WhatToHelpAsync,
                RetryWhatToHelpAsync,
                QnaGoToAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
        public NoPermissionDialog(LuisSetup luisRecognizer, ILogger <NoPermissionDialog> logger, UserState userState, IConfiguration configuration, IHttpClientFactory httpClientFactory, GoodbyeDialog goodbye)
            : base(nameof(NoPermissionDialog))
        {
            _recognizer        = luisRecognizer;
            _userState         = userState;
            _configuration     = configuration;
            _httpClientFactory = httpClientFactory;
            Logger             = logger;

            //AddDialog(new MainDialog());
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                PreQnaAsync,
                QnaAsync,
                RetryEnd,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#6
0
        public SendContactDialog(LuisSetup luisRecognizer, ILogger <SendContactDialog> logger, UserState userState, GoodbyeDialog goodbye, NoPermissionDialog noPermission)
            : base(nameof(SendContactDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(goodbye);
            AddDialog(noPermission);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                SendAsync,
                FinalStepAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#7
0
        public InfoSendNotClientDialog(LuisSetup luisRecognizer, ILogger <InfoSendNotClientDialog> logger, UserState userState, NoPermissionDialog noPermission, NoUnderstandDialog noUnderstand, GetPhoneDialog getPhone, GoodbyeDialog goodbye)
            : base(nameof(InfoSendNotClientDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noPermission);
            AddDialog(noUnderstand);
            AddDialog(getPhone);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                WantMoreAsync,
                YesNoAsync,
                RetryYesNoAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#8
0
        public GiveOptionsDialog(LuisSetup luisRecognizer, ILogger <GiveOptionsDialog> logger, UserState userState, WhereToReceiveDialog whereToReceive, NoUnderstandDialog noUnderstand, WantMoreDialog wantMore, GoodbyeDialog goodbye)
            : base(nameof(GiveOptionsDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(whereToReceive);
            AddDialog(noUnderstand);
            AddDialog(wantMore);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                GetMoreInfo,
                CheckMoreInfo,
                RetryCheckMoreInfo,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#9
0
        public IsClientDialog(LuisSetup luisRecognizer, ILogger <IsClientDialog> logger, UserState userState, NoUnderstandDialog noUnderstand, GetHelpDialog getHelp, GoodbyeDialog goodbye)
            : base(nameof(IsClientDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noUnderstand);
            AddDialog(getHelp);
            AddDialog(goodbye);


            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                AskNIFAsync,
                GetNIFAsync,
                ConfirmNIFAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#10
0
        public GiveOptionsNotClientDialog(LuisSetup luisRecognizer, ILogger <GiveOptionsNotClientDialog> logger, UserState userState, WhereToReceiveDialog whereTo, InfoSendNotClientDialog infoSend, NoUnderstandDialog noUnderstand, GoodbyeDialog goodbye)
            : base(nameof(GiveOptionsNotClientDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(whereTo);
            AddDialog(infoSend);
            AddDialog(noUnderstand);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                OptionAsync,
                MoreAsync,
                RetryMoreAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#11
0
        public IsNotClientDialog(LuisSetup luisRecognizer, ILogger <IsNotClientDialog> logger, UserState userState, GiveOptionsNotClientDialog giveOptions, NoUnderstandDialog noUnderstand, GoodbyeDialog goodbye, IHttpClientFactory httpClient, IConfiguration configuration)
            : base(nameof(IsNotClientDialog))
        {
            _recognizer        = luisRecognizer;
            _userState         = userState;
            Logger             = logger;
            _configuration     = configuration;
            _httpClientFactory = httpClient;

            //AddDialog(new MainDialog());
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(giveOptions);
            AddDialog(noUnderstand);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                HelpAsync,
                WhatToHelpAsync,
                RetryWhatToHelpAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
        public GetAssistantDialog(LuisSetup luisRecognizer, ILogger <GetAssistantDialog> logger, UserState userState, NoPermissionDialog noPermission, SuitCustomerNeedsDialog suitCustomer, NoUnderstandDialog noUnderstand, GoodbyeDialog goodbye)
            : base(nameof(GetAssistantDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noPermission);
            AddDialog(suitCustomer);
            AddDialog(noUnderstand);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                WantAsync,
                RetryWantAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#13
0
        public WhereToReceiveDialog(LuisSetup luisRecognizer, ILogger <WhereToReceiveDialog> logger, UserState userState, NoUnderstandDialog noUnderstand, GetAssistantDialog getAssistant, NoPermissionDialog noPermission, GoodbyeDialog goodbye)
            : base(nameof(WhereToReceiveDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            //AddDialog(new MainDialog());
            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(noUnderstand);
            AddDialog(getAssistant);
            AddDialog(noPermission);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                OkEmployeeAsync,
                EndOkEmployeeAsync,
                RetryEndOkEmployeeAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
        public NIFPermissionDialog(LuisSetup luisRecognizer, ILogger <NIFPermissionDialog> logger, UserState userState, IsClientDialog isClient, NoUnderstandDialog noUnderstand, IsNotClientDialog isNotClient, GoodbyeDialog goodbye)
            : base(nameof(NIFPermissionDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ChoicePrompt(nameof(ChoicePrompt)));
            AddDialog(isClient);
            AddDialog(noUnderstand);
            AddDialog(isNotClient);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                GiveNIFAsync,
                PermissionAsync,
                RetryPermissionAsync,
                EndAsync,
            }));

            InitialDialogId = nameof(WaterfallDialog);
        }
示例#15
0
        public MainDialog(LuisSetup luisRecognizer, ILogger <MainDialog> logger, UserState userState, NoUnderstandDialog noUnderstand, InitialServiceDialog initialService, TrueNoToMainDialog trueNoTo, GoodbyeDialog goodbye)
            : base(nameof(MainDialog))
        {
            _recognizer = luisRecognizer;
            _userState  = userState;
            Logger      = logger;

            AddDialog(new TextPrompt(nameof(TextPrompt)));
            AddDialog(new ConfirmPrompt(nameof(ConfirmPrompt)));
            AddDialog(noUnderstand);
            AddDialog(initialService);
            AddDialog(trueNoTo);
            AddDialog(goodbye);

            AddDialog(new WaterfallDialog(nameof(WaterfallDialog), new WaterfallStep[]
            {
                HelloDialog,
                AllowInfoStoreAsync,
                RetryAllowInfoStoreAsync,
                RedoDialog,
            }));

            // The initial child Dialog to run.
            InitialDialogId = nameof(WaterfallDialog);
        }