Skip to content

April 12th, 2021

The Five Step Journey to Becoming a Rasa Developer

  • portrait of Rachael Tatman

    Rachael Tatman

One question we get a lot is "what's the best way to learn Rasa?" While different types of learning materials work better for different people, there is a general journey that most developers follow as they learn to build Rasa assistants. In this post, we'll walk you through the major landmarks that most Rasa developers will run into in their developer journey and suggest materials that you might find helpful.

Step one: Installing Rasa Open Source

If you want to try Rasa out before you install anything, check out the Rasa playground in our docs. It will let you train and talk to your first assistant right in your browser!

Exactly what installing Rasa Open Source will look like will depend on your operating system. You can find guides here:

Rasa depends on both tensorflow and spaCy. These are both fantastic, powerful open source tools. (You can read more about why we use tensorflow specifically here.) For spaCy- and tensorflow-specific installation issues, check out their installation documentation.

Step two: Explore a sample assistant

Once you have Rasa Open Source installed, you're ready to start with your first assistant. (If you want to skip installation you can start with the Rasa playground instead and build your first assistant right in your browser, but you'll probably have to install Rasa at some point.)

The most common first step is to clone an existing assistant, which `rasa init` will do for you. This will let you see the Rasa file structure and build your understanding of what's what. Or, if you would prefer to start with a more fully-featured assistant, check out our Rasa starter packs.

Step three: Build your custom assistant

Once you've got a general idea of what a Rasa assistant needs and how it works, you can start to customize it. What sorts of conversations do you want your assistant to be able to have? What pieces of information do you want it to be able to pick out from the text your users input?

A note about conversations in Rasa: In the Rasa framework, you don't need to map out every possible way a conversation can go. Instead, you use Rasa stories, which are representations of conversations in a specific format, as training data to help the assistant learn.

For the initial development of your assistant, most of the work generally doesn't require you to write any code: just edit text files. You'll need to describe what things your assistant should know about in your domain file and also provide training data.

We've also built a framework that lets you quickly build out a lot of the most common use cases for assistants without having to write and maintain your own Python, for example:

  • I want to collect multiple pieces of information in one conversation (for this you can use a form. You might like this video tutorial or check out the documentation.)
  • I want to be able to quickly answer the same frequently asked questions (you can use a response selector for this; check out this step-by-step guide)
  • I need to know that when X happens, my assistant will always say the same thing (you can do this by using rules)

"What if I want my assistant to use a language other than English?" If your target language is one of the ones supported by spaCy then you can just change the two-level language code at the top of your config file. For other languages, this video provides an overview of what changes you may need to make the default pipeline for your specific language.

(Optional) Writing code for your assistant to run

Eventually, especially if you have a more complex use case, you may need your assistant to be able to do things in addition to having a conversation. You may want users to be able to interact with a database, for example, or you might need to check user's credentials.

The easiest way to do this is to have a second server that can run code triggered by certain events during the conversation (either based on rules you've specified or sample data you've provided in your stories). This video tutorial goes over custom actions.

You can create these custom actions using our Python SDK to write custom actions that can get information from and send it to your assistant, as well as executing any other code you need. If you prefer another language, our API is documented to make this easier.

(Optional) Customising the machine learning behind your assistant

In Rasa 2.x+, we've tried our best to provide a reasonable NLP pipeline when you first initialize your assistant. In general, most developers tend to see the biggest improvement in their assistant's performance by annotating more user-generated data, adding it to their training data and retraining.

Depending on your specific use case, however, you may want to customize your NLP pipeline or even add your own components to it. The simplest way to change your NLP pipeline is by editing your config file. If you're interested in more involved customization, you might find the following video series helpful.

  • NLP 4 Developers: High level introduction to various parts of the NLP pipeline, common approaches and benefits/drawbacks of each.
  • Algorithm whiteboard: A more detailed overview of different algorithms that may be used as part of your Rasa NLP pipeline.

Step four: Conversation Driven Development

When your assistant is able to handle most of the basic tasks you need, we recommend having other people use it as soon as possible. As anyone who's ever worked with conversational data is all too aware: users will surprise you! By improving your assistant to be better able to handle the real turns and conversations you didn't anticipate earlier in the development process, you'll quickly make your assistant more useful.

At Rasa we've developed the conversational-driven development or CDD framework to help you with this process. This basically means that you have people use your assistant, correct their data and add it as training data, make any changes you need for your assistant to be more successful in the future, retrain and redeploy.

Since this is such an important part of the conversational AI development process, we've also built a free software tool, Rasa X, to help you share your assistant, annotate data, and quickly retrain and redeploy as needed.

Step five: Deploy your assistant

Once you've verified that your assistant is working and done your first few rounds of conversation driven development, you'll be ready to start deploying your assistant.

The quickest way to deploy a Rasa assistant, especially to share with your first round of test users, is often using Rasa X: you can start by pointing users to the built-in web UI and add additional channels as you need. We also offer GitHub integration to support existing CI/CD pipelines.

We also offer a number of prebuilt connectors to let you use your assistant with popular messaging platforms including Telegram, Slack and Facebook Messenger. However, we've also tried to make it as easy as possible to build your own custom connectors.

The next step?

Wherever you are in your developer journey, from first installing Rasa to continuing to build out your assistant using Rasa Enterprise, we're delighted to have you as part of our developer community. Please feel free to ask questions on our forum, sign up for our newsletter to hear about upcoming events, subscribe to our YouTube channel, or even make a contribution to Rasa Open Source and we look forward to helping you build useful, impactful conversational AI projects.