Bot repeats action_listen - Augmentation not working?

I’ve currently started a bot project and work on a minimal example.

My bot has 3 stories:

## story 01


## story 02

    - utter_hello
## story 03
    - utter_hello

Basically, Story one and two define a reaction to two different intents. Story three also shows, that story 1 and 2 can be glued together.

My config:

language: de
pipeline: supervised_embeddings
- name: MemoizationPolicy
- name: KerasPolicy
- name: MappingPolicy

When i run the bot and replicate the stories, it only answers if the story mathces exactly. So, following conversations can happen:

  • Hi
  • Hello
  • What’s your name?
  • My name is Bot.

or (I have to restart the bot for this conversation)

  • What’s your name?
  • My name is Bot.

After these lines, no matter what I type, the bot always reacts with action_listen. When I debug, I see that for the first time the MemoizationPolicy jumps in and chooses correct reaction, but when the intent is repeated, it says “There is no memorised next action” and falls to keras_policy.

I want him to be able to loop my stories. Like answer to “Hi” several times or first tell the name and then answer to ‘Hi’. It seems however, that it only memorises exact stories, as if augmentation were not working (isn’t it supposed to glue my stories in several possible ways?).

Also I don’t understand, why it is not the problem for the Bot from Rasa Getting Started tutorial (the one with a picture to cheer up). You can chat with him much longer, repeating the same intents several times and getting an answer.

I use the same configuration (or at least I mean to use the same configuration, might I have overlooked something?) and the Tutorial bot doesn’t have significantly more trainigs data. It also remembers 5 last actions. What is the difference then?

P.S. I suppose I could have achieved the desired behaviour if I set max_history = 1 for “MemoizationPolicy”. However, I don’t want to do it right now, because I’m not sure it won’t get in the way later, when I design complex stories for the Bot. I’s rather see augmentation working properly so that my bot reaction won’t be confused by previous states.

I would be really greatful for some input.

P.P.S. This issue looks very similar Actions not working

Hi there, can you try using the AugmentedMemoizationPolicy instead of the MemoizationPolicy?

1 Like

Perfect! It worked. The name suggests, of course :slight_smile: Many thanks, especially for such a quick reply.

Any ideas why the AugmentedMemoizationPolicy was necessary and not the MemoizationPolicy, as in the Tutorial Bot?

I’ve been reading on AugmentedMemoizationPolicy, but theres is not much about in in the Docs. It was mentioned here, but nothing suggested that it is essential for repetitions.

Note: There is also an AugmentedMemoizationPolicy — you can use this instead if you don’t have slots set in prediction but they are present in your training data, basically this helps for the Memoization Policy to disregard slots in the tracker to consider a decision

Also according to this question, which addresses the same issue, combination of MemoizationPolicy and separate stories (like in my example and as in the answer to the linked question) should have been enough to ensure that the Bot can repeatedly answer same intents.

It would be really educating to understand how exactly augmentation works in both policies.