Hello Chandran it seems i cried victory too soon! It’s definitely working well when I enter order1 AND order2, but I get an error if I just enter 1 intem instead of 2 (ex.:order1):
> I want 1 coke
Rasa action server
2020-05-31 21:21:06 DEBUG rasa_sdk.executor - Received request to run 'restaurant_form'
Exception occurred while handling uri: 'http://localhost:5055/webhook'
Traceback (most recent call last):
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa_sdk/executor.py", line 387, in run
events = action(dispatcher, tracker, domain)
File "/Users/eduardobrigham/Rasa/rasa_EN/actions/actions.py", line 15, in run
a = next(tracker.get_latest_entity_values(entity_type="itemQty", entity_group = "1", entity_role="orderItem1"))
StopIteration
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/sanic/app.py", line 976, in handle_request
response = await response
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa_sdk/endpoint.py", line 102, in webhook
result = await executor.run(action_call)
RuntimeError: coroutine raised StopIteration
Rasa interactive --debug
Your input -> I want 1 coke
2020-05-31 21:24:22 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:24:22 DEBUG rasa.core.processor - Starting a new session for conversation ID 'f58da8adc1c64dc18546b15324ff4c08'.
2020-05-31 21:24:22 DEBUG rasa.core.processor - Action 'action_session_start' ended with events '[<rasa.core.events.SessionStarted object at 0x15ae17950>, <rasa.core.events.ActionExecuted object at 0x15ae17910>]'.
2020-05-31 21:24:22 DEBUG rasa.core.processor - Current slot values:
feedback: None
itemName: None
itemQty: None
preferences: None
requested_slot: None
tableNum: None
2020-05-31 21:24:22 DEBUG rasa.nlu.classifiers.diet_classifier - There is no trained model for 'ResponseSelector': The component is either not trained or didn't receive enough training data.
2020-05-31 21:24:22 DEBUG rasa.nlu.selectors.response_selector - Adding following selector key to message property: default
2020-05-31 21:24:22 DEBUG rasa.core.processor - Received user message 'I want 1 coke' with intent '{'name': 'itemName_order', 'confidence': 0.9990455508232117}' and entities '[{'entity': 'itemQty', 'start': 7, 'end': 8, 'value': '1', 'extractor': 'DIETClassifier'}, {'entity': 'itemName', 'start': 9, 'end': 13, 'value': 'coke', 'extractor': 'DIETClassifier'}]'
2020-05-31 21:24:22 DEBUG rasa.core.processor - Current slot values:
feedback: None
itemName: None
itemQty: None
preferences: None
requested_slot: None
tableNum: None
2020-05-31 21:24:22 DEBUG rasa.core.processor - Logged UserUtterance - tracker now has 4 events.
2020-05-31 21:24:22 DEBUG rasa.core.lock_store - Deleted lock for conversation 'f58da8adc1c64dc18546b15324ff4c08'.
2020-05-31 21:24:22 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
? Is the intent 'itemName_order' correct for 'I want [1](itemQty) [coke](itemName)' and are all entities labeled correctly? Yes
2020-05-31 21:25:02 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:02 DEBUG rasa.core.policies.fallback - NLU confidence threshold met, confidence of fallback action set to core threshold (0.3).
2020-05-31 21:25:02 DEBUG rasa.core.policies.memoization - Current tracker state [None, None, None, {}, {'entity_itemQty': 1.0, 'prev_action_listen': 1.0, 'entity_itemName': 1.0, 'intent_itemName_order': 1.0}]
2020-05-31 21:25:02 DEBUG rasa.core.policies.memoization - There is a memorised next action 'utter_greet'
2020-05-31 21:25:02 DEBUG rasa.core.policies.form_policy - There is no active form
2020-05-31 21:25:02 DEBUG rasa.core.policies.ensemble - Predicted next action using policy_1_MemoizationPolicy
2020-05-31 21:25:02 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
------
Chat History
# Bot You
──────────────────────────────────────────────────────────────
1 action_listen
──────────────────────────────────────────────────────────────
2 I want [1](itemQty) [coke](itemName)
intent: itemName_order 1.00
Current slots:
feedback: None, itemName: None, itemQty: None, preferences: None, requested_slot: None, tableNum: None
------
2020-05-31 21:25:02 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
? The bot wants to run 'utter_greet', correct? No
2020-05-31 21:25:05 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
------
Chat History
# Bot You
──────────────────────────────────────────────────────────────
1 action_listen
──────────────────────────────────────────────────────────────
2 I want [1](itemQty) [coke](itemName)
intent: itemName_order 1.00
Current slots:
feedback: None, itemName: None, itemQty: None, preferences: None, requested_slot: None, tableNum: None
------
2020-05-31 21:25:05 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
? What is the next action of the bot? 0.00 restaurant_form
Thanks! The bot will now run restaurant_form.
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.actions.action - Calling action endpoint to run action 'restaurant_form'.
2020-05-31 21:25:09 ERROR rasa.core.processor - Encountered an exception while running action 'restaurant_form'. Bot will continue, but the actions events are lost. Please check the logs of your action server for more information.
2020-05-31 21:25:09 DEBUG rasa.core.processor - Failed to execute custom action.
Traceback (most recent call last):
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa/core/actions/action.py", line 549, in run
json=json_body, method="post", timeout=DEFAULT_REQUEST_TIMEOUT
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa/utils/endpoints.py", line 154, in request
response.status, response.reason, await response.content.read()
rasa.utils.endpoints.ClientResponseError: 500, Internal Server Error, body='b'\n <h1>Internal Server Error</h1>\n <p>\n The server encountered an internal error and cannot complete\n your request.\n </p>\n''
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa/core/processor.py", line 644, in _run_action
events = await action.run(output_channel, nlg, tracker, self.domain)
File "/Users/eduardobrigham/Rasa/venv/lib/python3.7/site-packages/rasa/core/actions/action.py", line 572, in run
raise Exception("Failed to execute custom action.") from e
Exception: Failed to execute custom action.
2020-05-31 21:25:09 DEBUG rasa.core.processor - Action 'restaurant_form' ended with events '[]'.
2020-05-31 21:25:09 DEBUG rasa.core.processor - Current slot values:
feedback: None
itemName: None
itemQty: None
preferences: None
requested_slot: None
tableNum: None
2020-05-31 21:25:09 DEBUG rasa.core.lock_store - Deleted lock for conversation 'f58da8adc1c64dc18546b15324ff4c08'.
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
2020-05-31 21:25:09 DEBUG rasa.core.policies.fallback - NLU confidence threshold met, confidence of fallback action set to core threshold (0.3).
2020-05-31 21:25:09 DEBUG rasa.core.policies.memoization - Current tracker state [None, None, {}, {'entity_itemQty': 1.0, 'prev_action_listen': 1.0, 'entity_itemName': 1.0, 'intent_itemName_order': 1.0}, {'prev_restaurant_form': 1.0, 'entity_itemQty': 1.0, 'entity_itemName': 1.0, 'intent_itemName_order': 1.0}]
2020-05-31 21:25:09 DEBUG rasa.core.policies.memoization - There is no memorised next action
2020-05-31 21:25:09 DEBUG rasa.core.policies.form_policy - There is no active form
2020-05-31 21:25:09 DEBUG rasa.core.policies.mapping_policy - There is no mapped action for the predicted intent, 'itemName_order'.
2020-05-31 21:25:09 DEBUG rasa.core.policies.ensemble - Predicted next action using policy_0_FallbackPolicy
2020-05-31 21:25:09 DEBUG rasa.core.tracker_store - Recreating tracker for id 'f58da8adc1c64dc18546b15324ff4c08'
------
Chat History
# Bot You
────────────────────────────────────────────────────────────────
1 action_listen
────────────────────────────────────────────────────────────────
2 I want [1](itemQty) [coke](itemName)
intent: itemName_order 1.00
────────────────────────────────────────────────────────────────
3 restaurant_form
Current slots:
feedback: None, itemName: None, itemQty: None, preferences: None, requested_slot: None, tableNum: None