Disclaimer: A lot of things have changed and improved since we have launched Rasa X. To get the most up-to-date information about Rasa X you should check out this blogpost and our newly updated migration guide.
At Rasa, we are constantly looking for ways to make it easier for developers to build great conversational AI. Developing a conversational AI assistant is not an easy task, and improving it over time using real conversations that don't always go right is a whole new challenge. That's why we developed a brand new product - Rasa X! Read more why we built it here.
Rasa X is a tool designed to make it easier to deploy and improve Rasa-powered assistants by learning from real conversations.
Rasa X is packed with new UI features which allow you to:
- View and annotate conversations: Filter, flag, and fix conversations that didn't go well to continually improve your assistant.
- Get feedback from testers: Share your assistant with testers to get immediate feedback and more training data
- Version and manage models: Track and manage your models, promote to production, and easily roll back.
- Deploy anywhere: Ready-to-deploy Docker containers and orchestration to run Rasa on premise or using your favourite cloud provider.
Rasa X can also be used to develop an assistant from scratch, but our main goal behind developing it was to build a new UI tool which would make it as easy as possible for your assistant to improve by learning from real conversations.
So, do you have an assistant built with the open source Rasa framework and you're ready to take it to the next level? Enter Rasa X!
Step 1: Upgrading to Rasa 1.0
Alongside the launch of the Rasa X, the open source framework has reached an important milestone, with Rasa released as 1.0. It is the first version compatible with Rasa X and it comes with a bunch of new features like a new Mapping Policy, SQL tracker stores, new easy-to-use CLI and much more. Rasa 1.0 also is the first release of Rasa NLU and Core merged into one package.
To run Rasa X, you have upgrade to Rasa 1.0.
To upgrade, run:
The biggest new feature in Rasa 1.0 is a command line interface (CLI) which makes it much easier to train and test your NLU and dialogue models on the command line. The only thing you have to check is that your project's files are in the right place. Your NLU and dialogue data should be stored in a ./data directory in your project while all other files (domain, custom actions script, credentials, endpoints, nlu configuration file) should be kept in the main directory of your project folder. The image below represents the project structure the Rasa X expects to see:
After upgrading to Rasa 1.0 and updating your project structure, train a unified NLU and dialogue model by running the command below which will create a .tar.gz model file in a ./models directory:
With the files in this structure, you don't have to pass any flags to rasa commands to tell it where to find your domain, stories, etc. So the command really is just rasa train. If you have a different project structure, you can still pass in arguments like rasa train -d /path/to/domain.yml.
Once the model is trained, you can load it and talk to your assistant by running:
The command above will load your assistant for you to test. If, for example, you want to test only the NLU model, you can use:
The new CLI comes with a bunch of other handy commands which should make it easier to build and improve your assistants using the file system and a command line. Make sure to check out the documentation to see a detailed guide to the new CLI.
Step 2: Using Rasa X with your existing assistant
You can keep improving your assistant using the file system and command line, but a much easier way to take your assistant to a new level is to use Rasa X. Since you run Rasa X on your own machine, your training data and the conversations your users have with your assistant are kept completely private and never passed to Rasa. Ready to give Rasa X a spin? Let's go!
Extracting existing conversations from the tracker store
If you have existing conversations between your bot and the users persisted in a tracker store (MongoDB, Redis, or SQL), you can import them to Rasa X using the migration script. First, run the migration script on your command line:
The script will connect to your tracker store and extract the conversations into rasa.db and tracker.db files. Make sure they are placed in your project directory and you are good to open and annotate them using the Rasa X UI.
Annotating conversations using Rasa X
First, launch the Rasa X UI. In your project directory run the command below:
Once the Rasa X UI is launched, you can see the imported conversations in the Conversations tab of the Rasa X UI. Here, you can go through the conversations which were exported from your tracker store in the previous step and annotate them. The Conversations tab also lets you filter conversations by length, by specific intents and actions, and more. This comes in handy if you have a large number of conversations.
Training a model: your newly annotated data
To train a model with this new data, head to the Training tab in the Rasa X UI. Here, you can also find and edit your NLU training examples, response templates, NLU training pipeline parameters, and training stories you generated yourself:
Hit Train to train a model. Once the training has finished, the model will appear in the _Model_s tab of the Rasa X. Head to Models tab and move your trained model to the Production state so that it is ready for you and others to test:
Testing your assistant using Rasa X
You can test your assistant by heading to Talk to your bot tab of the Rasa X UI and simply having a conversation. Don't spend too much time being the only tester of your bot! While it's a good practice to test that your assistant works well before giving it to the real users, it needs real data Make sure that the basic version of your assistant works and then give it to the real users as soon as possible because it's the only way your assistant can really learn different conversation patterns. With Rasa X, it's very easy to let others test your assistant - all you have to do is generate a link to your bot by clicking on 'Share' icon in a Conversations tab and share it with your friends:
The testers of your assistant will be able to talk to it immediately without installing or setting up anything and you will see the conversations they have with your bot in the Conversations tab of the Rasa X UI. There, just like we did at the beginning of this tutorial, you can review them, annotate misclassified data, create more training stories and use them to continuously improve your assistant over time.
Let us know how you are getting on
We're releasing Rasa X in early access and here are a few useful resources to get started:
- Docs? → Rasa 1.0 here and Rasa X here
- Questions? → Post them in this forum thread
- Bugs? → Please file a bug report directly on Github
- Want more tips and tricks? → Join our free webinar on Thursday 10am - 11am EDT - RSVP here.
- Feedback? → Have you already used Rasa X? Please fill out this short feedback survey and help improve the product.