TED policy ignored while RulePolicy is always called

2020-11-10 12:42:39 DEBUG rasa.core.policies.memoization - Current tracker state [{‘user’: {‘intent’: ‘mood_great’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}, {‘user’: {‘intent’: ‘mood_great’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘utter_happy_greet’}}, {‘user’: {‘intent’: ‘affirm’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}, {‘user’: {‘intent’: ‘affirm’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘utter_which_exercise’}}, {‘user’: {‘intent’: ‘jumping_jacks’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}] 2020-11-10 12:42:39 DEBUG rasa.core.policies.memoization - There is no memorised next action 2020-11-10 12:42:39 DEBUG rasa.core.policies.rule_policy - Current tracker state: [{‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}}, {‘user’: {‘intent’: ‘greet’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}, {‘user’: {‘intent’: ‘greet’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘utter_greet’}}, {‘user’: {‘intent’: ‘mood_great’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}, {‘user’: {‘intent’: ‘mood_great’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘utter_happy_greet’}}, {‘user’: {‘intent’: ‘affirm’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}, {‘user’: {‘intent’: ‘affirm’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘utter_which_exercise’}}, {‘user’: {‘intent’: ‘jumping_jacks’}, ‘slots’: {‘current_exercise’: (0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0), ‘media_playback_control’: (0.0, 0.0, 0.0, 1.0), ‘reps’: (1.0,), ‘set_completed’: (1.0, 0.0)}, ‘prev_action’: {‘action_name’: ‘action_listen’}}] 2020-11-10 12:42:39 DEBUG rasa.core.policies.rule_policy - There is no applicable rule. 2020-11-10 12:42:39 DEBUG rasa.core.policies.ensemble - Predicted next action using policy_2_RulePolicy 2020-11-10 12:42:39 DEBUG rasa.core.processor - Predicted next action ‘action_my_fallback’ with confidence 0.30. 2020-11-10 12:42:39 DEBUG rasa.core.actions.action - Calling action endpoint to run action ‘action_my_fallback’.

It seems that fallback RulePolicy (instead of TED) is always called even when there exist training stories to deal with the current state. Can anyone help? Below is my config file:

language: en

pipeline:

  • name: WhitespaceTokenizer

  • name: RegexFeaturizer

  • name: LexicalSyntacticFeaturizer

  • name: CountVectorsFeaturizer

  • name: CountVectorsFeaturizer

    analyzer: char_wb

    min_ngram: 1

    max_ngram: 4

  • name: DIETClassifier

    epochs: 100

  • name: EntitySynonymMapper

  • name: ResponseSelector

    epochs: 100

  • name: FallbackClassifier

    threshold: 0.3

    ambiguity_threshold: 0.1

policies:

  • name: MemoizationPolicy

  • name: TEDPolicy

    max_history: 10

    epochs: 10

  • name: RulePolicy

    core_fallback_threshold: 0.3

    core_fallback_action_name: action_my_fallback

The current design is that if a rule applies that it determines the next action. Only when a rule does not apply will TED determine the next best action to take.

I just released a tutorial video on this topic here in case you’re interested in understanding the reasoning.

What about forms

In my case I have 2 forms 1st works fine I have given form for OTP based login. In same bot another form also ask for mob number to execute another custom action Here on deactivate of form the rule gets ignored and bot doesnt reply with form submit for second form.

In both story intent detected is deny as both ask ph number .Is that the reason.? But either ways why is decativate form rule defined doesnt execute after fill of slots.

As I see its ignoring the deactivate rule completely