Restart Conversation Best Practices

Hi everyone!

I’m very new to Rasa, so you might see me asking many questions. I don’t know which questions are dumb yet, or even the proper terminology to look up questions that may already have been answered. So bare with me while I get the hang of this! :slight_smile:

Project

I’m working on what essentially is a Home assistant very much in vain of Alexa and Google Home, but obviously a lot simpler - some chat bots that can help me control my home and do simple tasks for me. What I want to know, what are the best practices for always making sure my chatbot responds, even if it has failed before?

For example, here’s all I have in my stories.md so far - almost nothing so far, but there’s certain functionality I want present here already that is not.

## simple_greet
* greet
- utter_help

## deny_help
* greet
- utter_help
* deny
- utter_affirm

I might have a conversation like this:

Hey! -- greet
- Hi there. What can do I for you? -- utter_help
Yes. -- affirm
Whatever. -- undefined 
No responses. -- undefined
Hi! -- greet
*expect utter_help*

This isn’t defined in the stories, but I thought once I typed in a greet again, it would start again - but it doesn’t.

To make functionality, it looks like I have many options, but I’m not sure which one is best practice. The two main options I know about are:

  1. Use action_restart at places where the conversation has ended or has supposedly fail
  2. Use the MappingPolicy to trigger utter_help whenever there’s a greet intent or any other intend I want my bot to respond to no matter what came before it.

For (1) it seems a bit cumbersome to have to have many fail branches with - action_restart. (2) seems like the better option since I only need to define a few must act intents.

However, when I look at examples like the Sara demo, it doesn’t seem to use either of them. So is there something I’m missing in any of the other files used for training that would allow me to get a repeating conversations without using the MappingPolicy or action_restart?

NOTE: I haven’t been able to play with the Sara demo, I can’t seem to find it, and the instructions for use on the RasaHD/rasa-demo don’t work anymore. I’m assuming Saara doesn’t just stop working after the user fails to realize a story or finishes one, but allows the user to do something else, right?

I’ve looked through the examples in the /RasaHD/rasa repository, but they only seem to be a “run once” tests, our conversations end after stories are realized or failed.

So, again, my questions is: What is the best practice to keep conversations repeating and never ending in my situation for an assistant?

2 Likes

I’d be interested in knowing the answer to this as well. It seems like once the end of a story is reached, the bot will stop responding unless action_restart is called at the conclusion of the story. Surely this isn’t the intended behavior. Is there a way to have the bot switch to a different story?