Fallback returned after filling a form and form breaks after catching known intent

Hello, we’re facing an issue when using a simple form definition, without rule condition. As stated in documentation, bot should return action_listen after form gets filled, but keeps returning default fallback every time form gets filled with all requested_slots. Other related issue is that when a bot recognizes an intent inside the form, it returns fallback and stop the form immediately. Conversations are started from API e.g. /webhooks/rest/webhook. We have our custom action server, but we are not validating the slots yet.

Can you please help us track where the issue can be? Thank you

Here is model and two conversations one with fallback after form gets filled and second when an known intent matches conversation_1.json (12.4 KB) conversation_intent_break.json (10.7 KB) model.yml (7.3 KB)

Rasa logs:

[state 1] user intent: start_form | previous action name: action_listen
[state 2] user intent: start_form | previous action name: test_form | active loop: {'name': 'test_form'}
[state 3] user text: I live in London | previous action name: action_listen | active loop: {'name': 'test_form'} | slots: {'city': (1.0,)}
DEBUG    rasa.core.policies.rule_policy  - There is no applicable rule.
DEBUG    rasa.core.policies.rule_policy  - Predicted loop 'test_form'.
DEBUG    rasa.engine.graph  - Node 'run_TEDPolicy1' running 'TEDPolicy.predict_action_probabilities'.
DEBUG    rasa.core.policies.ted_policy  - TED predicted 'utter_1784678c1a6bac3257828837a100ccdc72219a98' based on user intent.
DEBUG    rasa.engine.graph  - Node 'select_prediction' running 'DefaultPolicyPredictionEnsemble.combine_predictions_from_kwargs'.
DEBUG    rasa.core.policies.ensemble  - Made prediction using user intent.
DEBUG    rasa.core.policies.ensemble  - Added `DefinePrevUserUtteredFeaturization(False)` event.
DEBUG    rasa.core.policies.ensemble  - Predicted next action using RulePolicy.
DEBUG    rasa.core.processor  - Predicted next action 'test_form' with confidence 1.00.
DEBUG    rasa.core.actions.forms  - Validating user input 'UserUttered(text: I live in London, intent: from_city, entities: London (Type: city, Role: None, Group: None), London (Type: city, Role: None, Group: None), use_text_for_featurization: False)'.
DEBUG    rasa.core.actions.forms  - Validating extracted slots: {'city': 'London'}
DEBUG    rasa.core.actions.forms  - Deactivating the form 'test_form'
DEBUG    rasa.core.processor  - Policy prediction ended with events '[<rasa.shared.core.events.DefinePrevUserUtteredFeaturization object at 0x7f1c9dce8040>]'.
DEBUG    rasa.core.processor  - Action 'test_form' ended with events '[<rasa.shared.core.events.SlotSet object at 0x7f1d80bdb700>, <rasa.shared.core.events.ActiveLoop object at 0x7f1da0e1ec10>]'.
DEBUG    rasa.core.processor  - Current slot values:
   cxoneexpert: None
   city: London
   last customer message: I live in London
   customer ID: None
   requested_slot: None
   session_started_metadata: None
DEBUG    rasa.engine.graph  - Node 'rule_only_data_provider' running 'RuleOnlyDataProvider.provide'.
DEBUG    rasa.engine.graph  - Node 'domain_provider' running 'DomainProvider.provide_inference'.
DEBUG    rasa.engine.graph  - Node 'run_AugmentedMemoizationPolicy0' running 'AugmentedMemoizationPolicy.predict_action_probabilities'.
DEBUG    rasa.core.policies.memoization  - Current tracker state:
[state 1] user intent: start_form | previous action name: action_listen
[state 2] user intent: start_form | previous action name: test_form | slots: {'city': (1.0,)}
DEBUG    rasa.core.policies.memoization  - Launch DeLorean...
DEBUG    rasa.core.policies.memoization  - Current tracker state [{}, {'slots': {'city': (1.0,)}, 'prev_action': {'action_name': 'test_form'}}]
DEBUG    rasa.core.policies.memoization  - There is no memorised next action
DEBUG    rasa.engine.graph  - Node 'run_RulePolicy2' running 'RulePolicy.predict_action_probabilities'.
DEBUG    rasa.core.policies.rule_policy  - Current tracker state:
[state 1] user intent: start_form | previous action name: action_listen
[state 2] user intent: start_form | previous action name: test_form | slots: {'city': (1.0,)}
DEBUG    rasa.core.policies.rule_policy  - There is no applicable rule.
DEBUG    rasa.engine.graph  - Node 'run_TEDPolicy1' running 'TEDPolicy.predict_action_probabilities'.
DEBUG    rasa.core.policies.ted_policy  - TED predicted 'test_form' based on user intent.
DEBUG    rasa.engine.graph  - Node 'select_prediction' running 'DefaultPolicyPredictionEnsemble.combine_predictions_from_kwargs'.
DEBUG    rasa.core.policies.ensemble  - Predicted next action using RulePolicy.
DEBUG    rasa.core.processor  - Predicted next action 'action_core_fallback' with confidence 0.40.
DEBUG    rasa.core.actions.action  - Calling action endpoint to run action 'action_core_fallback'.

Hi @ny4n ,

First thing, I would increase the number of epochs in your TED policy:

- name: TEDPolicy
    max_history: 6
    epochs: 20 # Try 50, 100...

Second, you can try reworking the form by following instructions here: Forms
I would split the activation and deactivation of the form in two. Also, this looks a bit odd:

      - active_loop: test_form
      - active_loop: ~ # Shouldn't this be null when deactivating?

Hope that helps

Thanks @E-dC for your response, we will try to raise the epochs. We are familiar how to deactivate the forms and ~ symbol means null in yaml too, the definition is the same.

Oh, that’s good to know about the ~ symbol, neat!