Code Monkey home page Code Monkey logo

rasa-demo's Introduction

Sara - the Rasa Demo Bot

Build Status

๐Ÿ„ Introduction

The purpose of this repo is to showcase a contextual AI assistant built with the open source Rasa framework.

Sara is an alpha version and lives in our docs, helping developers getting started with our open source tools. It supports the following user goals:

  • Understanding the Rasa framework
  • Getting started with Rasa
  • Answering some FAQs around Rasa
  • Directing technical questions to specific documentation
  • Subscribing to the Rasa newsletter
  • Requesting a call with Rasa's sales team
  • Handling basic chitchat

You can find planned enhancements for Sara in the Project Board

๐Ÿ‘ทโ€ Installation

To install Sara, please clone the repo and run:

cd rasa-demo
pip install -r requirements.txt
pip install -e .

This will install the bot and all of its requirements. Note that this bot should be used with python 3.6 or 3.7.

๐Ÿค– To run Sara:

Use rasa train to train a model (this will take a significant amount of memory to train, if you want to train it faster, try the training command with --augmentation 0).

Then, to run, first set up your action server in one terminal window:

rasa run actions --actions actions.actions

There are some custom actions that require connections to external services, specifically SubscribeNewsletterForm and SalesForm. For these to run you would need to have your own MailChimp newsletter and a Google sheet to connect to.

In another window, run the bot:

docker run -p 8000:8000 rasa/duckling
rasa shell --debug

Note that --debug mode will produce a lot of output meant to help you understand how the bot is working under the hood. To simply talk to the bot, you can remove this flag.

If you would like to run Sara on your website, follow the instructions here to place the chat widget on your website.

To test Sara:

After doing a rasa train, run the command:

rasa test nlu -u test/test_data.json --model models
rasa test core --stories test/test_stories.md

๐Ÿ‘ฉโ€๐Ÿ’ป Overview of the files

data/core/ - contains stories

data/nlu - contains NLU training data

actions - contains custom action code

domain.yml - the domain file, including bot response templates

config.yml - training configurations for the NLU pipeline and policy ensemble

โšซ๏ธ Code Style

To ensure a standardized code style we use the formatter black.

If you want to automatically format your code on every commit, you can use pre-commit. Just install it via pip install pre-commit and execute pre-commit install in the root folder. This will add a hook to the repository, which reformats files on every commit.

If you want to set it up manually, install black via pip install black. To reformat files execute

black .

๐ŸŽ License

Licensed under the GNU General Public License v3. Copyright 2018 Rasa Technologies GmbH. Copy of the license. Licensees may convey the work under this license. There is no warranty for the work.

rasa-demo's People

Contributors

akelad avatar alexweidauer avatar amn41 avatar arjaanbuijk avatar b-quachtran avatar btotharye avatar claverru avatar epedrotti avatar erohmensing avatar github-actions[bot] avatar hellonu avatar indam23 avatar ksurya avatar ls1707 avatar mrjazz avatar msamogh avatar rgstephens avatar tabergma avatar tydunn avatar wochinge 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.