TL;DR - rasa test
stops mid test, console dump below
Details -
I have a new (not upgraded) small talk bot with 90 intents, 90 stories and my nlu.yml
file is 9977 lines long. The model trains with no issues, other than it takes about 57 minutes and rasa shell
works and the bot responds properly when playing around.
Iβve created 6 simple tests to get started, all with a single user phrase, intent and action like this
- story: Greeting 1
steps:
- user: |
Hi
intent: greet
- action: utter_greet
When I run my command, I get a few odd errors. The results
directory is generated with the expected files, but the test just stops when performing Entity evaluation
:
rasa test --stories tests/small_talk_tests.yml --fail-on-prediction-errors
2021-01-13 08:46:54 INFO rasa.model - Loading model models/20210107-172420.tar.gz...
2021-01-13 08:47:00 INFO rasa.core.test - Evaluating 0 stories
Progress:
0it [00:00, ?it/s]
2021-01-13 08:47:00 INFO rasa.core.test - Finished collecting predictions.
2021-01-13 08:47:00 WARNING rasa.test - No labels to evaluate. Skip evaluation.
2021-01-13 08:47:00 INFO rasa.core.test - Evaluation Results on END-TO-END level:
2021-01-13 08:47:00 INFO rasa.core.test - Correct: 0 / 0
2021-01-13 08:47:00 INFO rasa.core.test - F1-Score: 0.000
2021-01-13 08:47:00 INFO rasa.core.test - Precision: 0.000
2021-01-13 08:47:00 INFO rasa.core.test - Accuracy: 0.000
2021-01-13 08:47:00 INFO rasa.core.test - In-data fraction: 0
2021-01-13 08:47:00 WARNING rasa.test - No labels to evaluate. Skip evaluation.
2021-01-13 08:47:00 INFO rasa.core.test - Stories report saved to results/story_report.json.
2021-01-13 08:47:01 INFO rasa.core.test - Evaluation Results on ACTION level:
2021-01-13 08:47:01 INFO rasa.core.test - Correct: 0 / 0
2021-01-13 08:47:01 INFO rasa.core.test - F1-Score: 0.000
2021-01-13 08:47:01 INFO rasa.core.test - Precision: 0.000
2021-01-13 08:47:01 INFO rasa.core.test - Accuracy: 0.000
2021-01-13 08:47:01 INFO rasa.core.test - In-data fraction: 0
/home/jwheat/anaconda2/envs/rasa2/lib/python3.8/site-packages/rasa/utils/plotting.py:75: UserWarning: Attempting to set identical left == right == -0.5 results in singular transformations; automatically expanding.
plt.imshow(
/home/jwheat/anaconda2/envs/rasa2/lib/python3.8/site-packages/rasa/utils/plotting.py:75: UserWarning: Attempting to set identical bottom == top == -0.5 results in singular transformations; automatically expanding.
plt.imshow(
2021-01-13 08:47:01 INFO rasa.utils.plotting - Confusion matrix, without normalization:
[]
2021-01-13 08:47:02 INFO rasa.model - Loading model models/20210107-172420.tar.gz...
2021-01-13 08:47:05 INFO rasa.nlu.test - Running model for predictions:
100%|βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ| 9701/9701 [01:02<00:00, 154.45it/s]2021-01-13 08:48:08 INFO rasa.nlu.test - Intent evaluation results:
2021-01-13 08:48:08 INFO rasa.nlu.test - Intent Evaluation: Only considering those 9701 examples that have a defined intent out of 9701 examples.
/home/jwheat/anaconda2/envs/rasa2/lib/python3.8/site-packages/sklearn/metrics/_classification.py:1221: UndefinedMetricWarning: Precision and F-score are ill-defined and being set to 0.0 in labels with no predicted samples. Use `zero_division` parameter to control this behavior.
_warn_prf(average, modifier, msg_start, len(result))
/home/jwheat/anaconda2/envs/rasa2/lib/python3.8/site-packages/sklearn/metrics/_classification.py:1221: UndefinedMetricWarning: Precision is ill-defined and being set to 0.0 in labels with no predicted samples. Use `zero_division` parameter to control this behavior.
_warn_prf(average, modifier, msg_start, len(result))
2021-01-13 08:48:08 INFO rasa.nlu.test - Classification report saved to results/intent_report.json.
2021-01-13 08:48:08 INFO rasa.nlu.test - Incorrect intent predictions saved to results/intent_errors.json.
2021-01-13 08:48:08 INFO rasa.utils.plotting - Confusion matrix, without normalization:
[[223 1 0 ... 0 0 0]
[ 0 44 0 ... 0 0 0]
[ 0 0 116 ... 0 0 0]
...
[ 0 0 0 ... 150 0 0]
[ 0 0 0 ... 0 13 0]
[ 0 0 0 ... 0 0 294]]
2021-01-13 08:48:55 INFO rasa.nlu.test - Entity evaluation results:
It literally stops right there and gives me my cursor back. It never actually runs my story tests. I know this because I set a bogus intent that should make the story fail
- story: Greeting 1
steps:
- user: |
Hi
intent: xxxgreet
- action: utter_greet
I get the same output with the incorrect xxxgreet
intent.
I see an couple warnings about No labels to evaluate
, a python UserWarning
and UndefinedMetricWarning
Iβve never seen any of those errors before. This is the first time Iβve tried testing a 2.x bot outside the normal out-of-the-box mood bot, so maybe Iβm missing something.
Hereβs my version information
Rasa Version : 2.1.3
Rasa SDK Version : 2.1.2
Rasa X Version : None
Python Version : 3.8.0
Operating System : Linux-4.4.0-19041-Microsoft-x86_64-with-glibc2.10
Python Path : /home/jwheat/anaconda2/envs/rasa2/bin/python
Any ideas?