Bot init conversation

Hello, I am starting with rasa and I want to make a chatbot that starts talking before the user, I attach an example:

Bot: Hello, how can I help you?
User: Hello, what time is it?
Bot: It's 5:23 p.m.

I know how to make the user write first but I don’t know how to do it the other way around. I have been looking for information and saw this link: How to let bot start the conversation - #5 by JiteshGaikwad but it is still up to the user to write first

I’ve this: stories.yml

- story: greet
  - action: action_utter_supply_greet_user
  - intention: greet
.... (continues)

class ActionGreetUser(Action):
    def name(self) -> Text:
        return "action_utter_supply_greet_user"
    def run(self, dispatcher: CollectingDispatcher,
            tracker: Tracker,
            domain: Dict[Text, Any]) -> List[Dict[Text, Any]]:
        dispatcher.utter_message("Hello! How can I help you?")


  - action_utter_supply_greet_user

What’s wrong? How can I do it?


  1. Look at ActionSessionStart and try to implement it.

  2. If it doesn’t work, it means you will have to do it from your front-end application. More details here: How to Add Welcome message in RASA X? - #9 by ChrisRahme

  3. Here, Jitesh is explaining how to make that happen by forcing the bot to execute an action from the front-end. My alternative is sending an intent from the front-end, which will itself execute an action.

1 Like

Thank you very much I will read what you have sent me and try to apply it.

1 Like

Don’t hesitate to get back to me if you have any problems :slight_smile:

1 Like

I’ve a small doubt to use your method I must have an external interface, I mean, right now I test the chatbot from the python terminal itself, no external page is opened.

Yes, you need an interface for methods 2 and 3.

But aren’t you planning on having one?

Yes, but it was a future thing, I wasn’t planning to implement it so soon :sweat_smile:

@Paulllllaaa you can try any method, as suggested by chris, but for display a bot init conversation you need an interface and If you want to implement the one please see this link : Rasa chatbot website integration | Quick tutorial - YouTube it have everything mentioned. I hope this will solve your issue.

1 Like

Thank you very much !

You can try the first method meanwhile if it’s really urgent :slight_smile:

But I couldn’t make it work last time I tried it.

1 Like

No, it doesn’t work :sleepy:

Yeah, I couldn’t make it work either haha.

I still suggest doing it from your front-end application, but if you still want to go with the back-end method, show me what you did and we’ll try to fix it.

Or, try out this other method, which requires you to build your own custom channel.

I tried to create a web interface but it didn’t work very well :frowning: I tried to do the same as here but it didn’t work

There are already multiple frontends you can use:

  1. Chatbot Widget by Jitesh Gaikwad (web)
  2. WebApp by me (web)
  3. Webchat by Botfront (web)
  4. Chatroom by ScalableMinds (web)
  5. Rasa Android by Dishant Ghandi (mobile)
  6. MobApp by me (mobile)

You can use one of them and edit it as you wish, easier than building your own :slight_smile:

I am familiar with #1, #2, and #6 if you need any help.

1 Like

I just got back, I’m going to try one of those three. Thanks for everything

1 Like