Coder Social home page Coder Social logo

naterickard / cycleshopbot Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 3.26 MB

Azure Bot Framework demo using LUIS, Bot Builder SDK, Dialogs, AdaptiveCards, and more

License: MIT License

JavaScript 15.31% Batchfile 3.42% C# 81.26%
sap-hana bot-framework bot botbuilder-sdk azure azure-functions luis-ai node-js csharp

cycleshopbot's Introduction

Cycle Shop Bot

A demo Azure Bot Framework sales bot for a fictitious cycling shop. Say "Hi" and it will guide you on some of the things it can help with.

Highlights:

  • An Azure Function-based backend (compiled C# function)
  • Bot Builder C# SDK (v3.15.2.2 - current production/stable release as of this writing)
  • LUIS language understanding model for:
    • Triggering different intents/dialogs within the bot
    • Maintaining domain lists for product offerings & regions using LUIS List Entities
  • Many bot features:
    • Multiple bot Dialogs and dialog transfer (Call, Fail, etc.)
    • Adaptive Cards and other card support
    • Suggested Actions
    • Choice prompts
    • Postback card actions
    • Example of inspecting current channel and altering behavior per channel
  • Calling into Node.js functions hosted side by side with C# functions
  • A demo mode to use/demo the bot without needing the SAP instance

Sample Conversation UI

Via the Bot Framework Emulator v3

Setup

  1. Create a bot in the Azure portal using the Functions Bot template.

  2. Go to the LUIS dashboard and find the new LUIS application that was created as a part of the bot template. Import the json model found in the /data folder. Train and publish the model.

  3. Add an application setting named MockData and set its value to true.

  4. Download the new bot source from the portal.

    NOTE: You may need to do this from the Functions UI in Azure (Build tab -> "Open this bot in Azure Functions" -> "Download app content", making sure to check the box to include the app settings file).

  5. Grab the local.settings.json file from the downloaded content and add/include this into the Cycle Shop solution root. Verify it contains the newly added MockData setting and add it if needed.

  6. Build the solution and Publish your Cycle Shop Bot solution to Azure, or Set up continuous deployment via your source code repo.

  7. Once the Function(s) have been deployed in Azure, you may need to review and change the messaging endpoint for your bot. Your messaging endpoint can be found in the Azure Functions UI via the "Get function URL" link when you've selected the CycleShopBot Function.

  8. Test your bot via the Test in Web Chat feature.

  9. Enable any Channels you want the bot to be available on.

Having trouble? Log an issue here and I'll try to help.

Debugging

To learn how to debug Azure Bot Service bots, please visit https://aka.ms/bf-docs-azure-debug.

To debug locally, you'll need to configure your dev environment and run/debug the Azure function(s) locally. Then you can use the locally running bot by connecting the Bot Framework Emulator to the locally running bot Function.

About

Contributors

License

Licensed under the MIT License (MIT). See LICENSE for details.

cycleshopbot's People

Contributors

naterickard avatar steverhall avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.