Rasa Tracker (Iterate)

Hey,

I’m having some difficulties creating a quiz with rasa. It’s quite simple as you can see in the graphic (see bellow). The problem I have now is that I want to iterate 5 times between question and answer until the user will be presented with his final score.

In Dialogflow I would just use contexts for it. How do I do it here? I think tracker will be the key, but I don’t fully get how it works yet.

  1. How can I use iterations in this case?

  2. Can somebody give me some more infos about the tracker functionality or post a link where it will be explained a bit more?

https://rasa.com/docs/rasa/api/tracker/

For this I would probably use a form, where you collect the user’s answers as 5 requested slots: [q1_answer, q2_answer, q3_answer, q4_answer, q5_answer]. Then on submit you can grade the answers.

You can add variety into the way you ask the questions (instead of hardcoding what is q1, q2, etc, by overwriting the request_next_slot function of the form.

1 Like