rizul
(Rizul Goyal)
July 23, 2019, 12:23pm
1
Hi, I am trying to introduce a Sentiment Analyzer in RASA NLU pipelinE. I am using this blog for refrence https://blog.rasa.com/enhancing-rasa-nlu-with-custom-components/ .
But, I am receiving an unhandled error. I am using rasa version 0.15.0.
It would be great, If anyone can help me with with some other reference codes on custom components or sentiment analyzer or a guide of steps to follow to add a custom component in NLU pipeline.
#CustomComponent
#RASANLU
#Pipeline
Hello!
It would be better if you copied the error message. I was also having some issues in adding custom components. Maybe this link can help you with the basic steps:
https://github.com/RasaHQ/rasa/issues/3748#issuecomment-503589073
rizul
(Rizul Goyal)
July 24, 2019, 10:02am
3
Following is the error, I am getting.
2019-07-24 14:41:18+0530 [-] 2019-07-24 14:41:18 WARNING rasa_nlu.data_router - [Failure instance: Traceback (failure with no frames): <class 'rasa_nlu.train.TrainingException'>: <TrainingException instance at 0x7fb3694af708 with str error:
2019-07-24 14:41:18+0530 [-] Traceback (most recent call last):
2019-07-24 14:41:18+0530 [-] File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/python/reflect.py", line 448, in safe_str
2019-07-24 14:41:18+0530 [-] return str(o)
2019-07-24 14:41:18+0530 [-] TypeError: __str__ returned non-string (type int)
2019-07-24 14:41:18+0530 [-] >
2019-07-24 14:41:18+0530 [-] ]
2019-07-24 14:41:18+0530 [-] Unhandled Error
Traceback (most recent call last):
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/internet/defer.py", line 501, in errback
self._startRunCallbacks(fail)
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/internet/defer.py", line 568, in _startRunCallbacks
self._runCallbacks()
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/internet/defer.py", line 654, in _runCallbacks
current.result = callback(current.result, *args, **kw)
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1475, in gotResult
_inlineCallbacks(r, g, status)
--- <exception caught here> ---
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/internet/defer.py", line 1416, in _inlineCallbacks
result = result.throwExceptionIntoGenerator(g)
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/twisted/python/failure.py", line 512, in throwExceptionIntoGenerator
return g.throw(self.type, self.value, self.tb)
File "/home/ori/Documents/rizul/my_env/lib/python3.6/site-packages/rasa_nlu/server.py", line 298, in train
returnValue(json_to_string({"error": "{}".format(e)}))
builtins.TypeError: __str__ returned non-string (type int)
erohmensing
(Ella Rohm-Ensing)
July 29, 2019, 11:38am
4
Hm, haven’t seen this one before. However, I think that that tutorial was updated to run on rasa 1.0.0 and later, not the unmerged NLU and Core. Can you try updating to the latest rasa
?