Rasa ignoring rule

Hi All, This is a strange one. I have a rule set up which is pretty simple:

- rule: submit reflection as it is (done)
  steps:
  - intent: submit_as_is
  - action: action_process_reflections
  - action: utter_submit_as_is

However when the intent is called, the rule is not activated. I can’t understand why. Any ideas? Here’s the output:

[state 8] user intent: submit_as_is | previous action name: action_listen | slots: {'reflection_len_ok': (1.0, 1.0), 'assignment': (1.0,)}
2021-08-14 09:09:17 DEBUG    rasa.core.policies.rule_policy  - There is no applicable rule.
2021-08-14 09:09:17 DEBUG    rasa.core.policies.ensemble  - Made prediction using user intent.
2021-08-14 09:09:17 DEBUG    rasa.core.policies.ensemble  - Added `DefinePrevUserUtteredFeaturization(False)` event.
2021-08-14 09:09:17 DEBUG    rasa.core.policies.ensemble  - Predicted next action using policy_0_RulePolicy.
2021-08-14 09:09:17 DEBUG    rasa.core.processor  - Predicted next action 'action_listen' with confidence 0.00.
2021-08-14 09:09:17 DEBUG    rasa.core.processor  - Policy prediction ended with events '[<rasa.shared.core.events.DefinePrevUserUtteredFeaturization object at 0x7f5488cffdd8>]'.
2021-08-14 09:09:17 DEBUG    rasa.core.processor  - Action 'action_listen' ended with events '[]'.
2021-08-14 09:09:17 DEBUG    rasa.core.lock_store  - Deleted lock for conversation 'cd74c3f6581c4c7c8cef18d4df366b9b'.

So as you can see, the intent is clearly seen by rasa, but despite that, it says there is no applicable rule.
Version 2.7.1
SDK 2.7.0
I’ve attached my config.yml file in case that is of interest. config.yml (1.3 KB)

1 Like

@Randywreed Hi, as seen your config.yml you not uncommented RulePolicy.config.yml (1.3 KB) check and try again.

policies:
# # No configuration for policies was provided. The following default policies were used to train your model.
# # If you'd like to customize them, uncomment and adjust the policies.
# # See https://rasa.com/docs/rasa/policies for more information.
  - name: MemoizationPolicy
  - name: RulePolicy
  - name: TEDPolicy
    max_history: 5
    epochs: 100
    constrain_similarities: true

My rule policy is uncommented (though maybe you’re saying it shouldn’t be). The file didn’t upload correctly. This is it:

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
  constrain_similarities: true
  model_confidence: softmax
- name: EntitySynonymMapper
- name: ResponseSelector
  epochs: 100
  constrain_similarities: true
  model_confidence: softmax
- name: FallbackClassifier
  threshold: 0.1
  ambiguity_threshold: 0.1
- name: RegexEntityExtractor
  case_sensitive: false
  use_lookup_tables: true
  use_regexes: true
  use_word_boundaries: true
policies:
- name: "RulePolicy"
  core_fallback_threshold: 0.1
  core_fallback_action_name: "action_default_fallback"
  enable_fallback_prediction: false
- name: MemoizationPolicy
- name: TEDPolicy
  max_history: 5
  epochs: 10

@Randywreed The one is attached, in that it is commented, it good if it’s not commented and its looking like the one you posted recently. Did the problem still persisted ?

Yes. Even though the rule policy is uncommented. It still ignores the rule. Other rules are obeyed but this one it does not recognize. It comes after a form has been deactivated and then a message with two button appears. Clicking a button should call the rule. But while the intent is recognized, the rule is not activated. I cannot understand why.

facing same issue in 2.8.1