Thanks to @znat , I have noticed the following.
In the rasa_nlu.utils files there is a function called class_from_module_path which is called if the component is not found in the list of components in registry.py.
"""Given the module name and path of a class, tries to retrieve the class.
The loaded class can be used to instantiate new objects. """
# load the module, will raise ImportError if module cannot be loaded
if "." in module_path:
module_name, _, class_name = module_path.rpartition('.')
m = importlib.import_module(module_name)
# get the class, will raise AttributeError if class cannot be found
return getattr(m, class_name)
Therefore you could try to call in your main file :
from rasa_nlu import utils
and it should work. In the case, this works but you still get the error ‘‘Failed to find…’’ then maybe you haven’t written properly the name of your component in the config file. If you use a .yml config file it should look like the following :
- name: "a.b.B"
Hope this helps !
P.S. I am using rasa_nlu==0.13.7