Yes I did that one. But the button is not created, only “It seems that you are facing login issue.Am I correct?” that message is displaying.
I have also used dispatcher.utter_button_message(“utter_login_confirm”) that one. But using this also button is not created.
Actually I want a create two buttons after displaying that message.
domain.yml
utter_login_confirm:
- text: “It seems that you are facing some login related issue am I correct ?”
buttons:
- title: “yes”
payload: “/intent_affirm”
- title: “No”
payload: “/intent_deny”
after running that one I got this type of error :
DEBUG:rasa_core.policies.memoization:Current tracker state [None, {}, {‘entity_issueType’: 1.0, ‘intent_intent_login_issue’: 1.0, ‘prev_action_listen’: 1.0}]
DEBUG:rasa_core.policies.memoization:There is a memorised next action ‘33’
DEBUG:rasa_core.policies.ensemble:Predicted next action using policy_0_MemoizationPolicy
DEBUG:rasa_core.policies.ensemble:Predicted next action ‘utter_login_confirm’ with prob 1.00.
DEBUG:rasa_core.processor:Bot utterance ‘BotUttered(text: It seems that you are facing some login related issue am I correct ?, data: {
“buttons”: [
{
“title”: “yes”,
“payload”: “/intent_affirm”
},
{
“title”: “No”,
“payload”: “/intent_deny”
}
]
})’
DEBUG:rasa_core.processor:Action ‘utter_login_confirm’ ended with events ‘[]’
DEBUG:rasa_core.policies.memoization:Current tracker state [{}, {‘entity_issueType’: 1.0, ‘intent_intent_login_issue’: 1.0, ‘prev_action_listen’: 1.0}, {‘entity_issueType’:
1.0, ‘intent_intent_login_issue’: 1.0, ‘prev_utter_login_confirm’: 1.0}]
DEBUG:rasa_core.policies.memoization:There is a memorised next action ‘4’
DEBUG:rasa_core.policies.ensemble:Predicted next action using policy_0_MemoizationPolicy
DEBUG:rasa_core.policies.ensemble:Predicted next action ‘action_on_button’ with prob 1.00.
ERROR:rasa_core.processor:Encountered an exception while running action ‘action_on_button’. Bot will continue, but the actions events are lost. Make sure to fix the excepti
on in your custom code.
ERROR:rasa_core.processor:name ‘buttons’ is not defined
Please help. I am unable to create buttons within chatbox.
what was the mistake. I am getting stuck at the same place.
i am getting:
TypeError: utter_button_template() missing 2 required positional arguments: ‘buttons’ and ‘tracker’
Hi neerajb1. Thanks for the response.
I am still not clear.
I have defined buttons in the templates in the domain.yml as :
utter_ask_loan:
text: “what kind of loan you have??”
buttons:
title: “low”
payload: “low”
title: “medium”
payload: “medium”
title: “high”
payload: “high”
Now I am calling it in my actions.py as:
dispatcher.utter_button_template(“utter_ask_loan”)
and have tried many other variations of this.
Please let me know as in where to define the button and how to call in the actions.py.
I get the error as two arguments missing: buttons and tracker