Tracker to store custom conversation-wide metadata

Hi, I’m fairly new to Rasa and astonished at what possibilities it provides. :slight_smile:

There is a question I currently have for a use case and I hope I can get some insights into how to achieve this: I would like to get some external data “into a conversation” and use it there. It will be some kind of ordered structure of unknown content from which parts will get uttered by the bot one by one, as the conversation proceeds.

So far, I worked out how to do this via forms and custom actions. The biggest obstacle I’m facing now, though, is how to get this data into the tracker, store it there and modify it after each conversation step. Or is that even the best solution?

It would awesome to get some help here!

@Christine Hi, means you want to store the bot/user conversation while using tracker store which store the data into database and then you can modify and used it again for your use case, is that right?

@nik202 Hey :-), not even the whole conversation, but (some of) the content that the bot will utter. The problem is that parts of it are unknown and I cannot model this directly via responses. So, I thought, I’d use a custom action and have it uttered via dispatcher.utter_message. I just don’t know how to keep track of it during the conversation - and how to import it into Rasa on start of conversation.

Just for explanation, the data could be a simple list [a, b, c]. Then the conversation could be something like (reeeaaalllly simplified; it does not make much sense this way :wink: ):

  • user: “hi”
  • bot “a”
  • user: “next please”
  • bot: “b”
  • user: “and next”
  • bot: “c”

(I also read about Custom Connectors, but there seems to be only metadata per message; could be a start, though, I guess…)

@Christine Ok, means what ever you talk with bot, you customise that later and then process and show to the user? or you want to fetch the data from the database and show to the user.

@nik202 Yes, point 1 you describe, i.e. what the bot utters, I need to customize.

Not the whole conversation. Parts of it can be modelled just as usual, by setting up responses and using in stories. But other parts of the conversation are described as above.

@Christine I hope you aware of TrackerStore?

Bot Utterance you need to customise? I guess that you only trained the bot on?

@nik202 yes, I (so far) read about the tracker store. Any hints on how to use this for the described use case? First I thought I’d customize the tracker itself, but I guess that’s not an option?

@Christine Well, your use case is very complex, on the other hand, tracker store store the data (bot/user conversation) in any database, but you can use to see all the --debug and write a custom python code for your use case.

@nik202 Yes, that’s what I feared, that the use case is quite complex and needs lots of customization. But it’s good to know or get some confirmation on what to concentrate on. I think, what would be cool is if the standard tracker was easy to extend, so it could maybe hold general data - in addition to what is stored under

@Christine will show you all the bot/user conversation and you can write custom code to fetch the specific data from that. Even, if you want to store the bot/user conversation while using and then while writing some code for fetching the data from SQL, that also you can do it.