Skip to content

Commit

Permalink
Merge pull request RasaHQ#338 from RasaHQ/new-new-getting-started
Browse files Browse the repository at this point in the history
Match latest getting started flow (discussion)
  • Loading branch information
akelad authored Nov 13, 2019
2 parents ee24fbc + 2b9e67e commit 53982d6
Show file tree
Hide file tree
Showing 19 changed files with 2,158 additions and 1,578 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ language: python
sudo: required
services:
- docker
- xvfb
python:
- '3.6'
before_install:
- python -m pip install -U pip
- pip install -e . --no-use-pep517
- export DISPLAY=0.0
- make train-memo
- rasa train core --config augmentedmemo-only.yml --augmentation 0 --quiet
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
- sleep 3 # give xvfb some time to start
- make evaluate-core
- rasa test core --fail-on-prediction-errors --quiet
- openssl aes-256-cbc -K $encrypted_8857e34a5e52_key -iv $encrypted_8857e34a5e52_iv
-in travis_gcloud_auth.json.enc -out travis_gcloud_auth.json -d
- docker login -u _json_key -p "$(cat travis_gcloud_auth.json)" https://gcr.io
Expand Down
30 changes: 0 additions & 30 deletions Makefile

This file was deleted.

42 changes: 27 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@
## :surfer: 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 (temporarily she's unavailable on the docs due to maintenance), helping developers getting started with our open source tools. It supports the following user goals:
Sara is an alpha version and lives in our docs (temporarily she's unavailable on the docs due to maintenance),
helping developers getting started with our open source tools. It supports the following user goals:

- Understanding the Rasa framework
- Installing the Rasa framework
- Getting started with Rasa
- Answering some FAQs around Rasa
- Subscribing to the Rasa newsletter
- Requesting a call with Rasa's sales team
Expand All @@ -16,32 +17,43 @@ Sara is an alpha version and lives in our docs (temporarily she's unavailable on
You can find planned enhancements for Sara in the
[Project Board](https://github.com/RasaHQ/rasa-demo/projects/1)

## 🤖 How to install and run Sara
## 👷‍ 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 it was written in Python 3 so might not work with PY2.
Note that this bot should be used with python 3.6 or 3.7.

To train the model: `make train` (this will take a significant amount of memory to train,
## 🤖 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`)
`--augmentation 0`).

To run Sara with both these models:
```
docker run -p 8000:8000 rasa/duckling
make run-cmdline
Then, to run, first set up your action server in one terminal window:
```bash
rasa run actions --actions demo.actions
```

There are some custom actions that require connections to external services,
specifically `ActionSubscribeNewsletter` and `ActionStoreSalesInfo`. For these
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:
```bash
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](https://github.com/mrbot-ai/rasa-webchat) to place the chat widget on
your website.
Expand All @@ -50,15 +62,15 @@ your website.

`data/core/` - contains stories

`data/nlu` - contains example NLU training data
`data/nlu` - contains NLU training data

`demo` - contains custom action/api code

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

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

### Code Style
## ⚫️ Code Style

To ensure a standardized code style we use the formatter [black](https://github.com/ambv/black).

Expand Down
5 changes: 5 additions & 0 deletions config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,13 @@ pipeline:
- name: CountVectorsFeaturizer
OOV_token: oov
token_pattern: (?u)\b\w+\b
- name: CountVectorsFeaturizer
analyzer: "char_wb"
min_ngram: 1
max_ngram: 4
- name: EmbeddingIntentClassifier
epochs: 50
loss_type: margin
- name: DucklingHTTPExtractor
url: http://localhost:8000
dimensions:
Expand Down
Loading

0 comments on commit 53982d6

Please sign in to comment.