Rasa NLU 版本(例如0.7.3
):rasa-nlu-0.11.3
使用的后端/管道:spacy_sklearn
操作系统:Windows 10
问题:我正在尝试按照 rasa 网站中所述的示例代码进行培训。
from rasa_nlu.training_data import load_data
from rasa_nlu.config import RasaNLUConfig
from rasa_nlu.model import Trainer
training_data = load_data('data/examples/rasa/demo-rasa.json')
trainer = Trainer(RasaNLUConfig("sample_configs/config_spacy.json"))
trainer.train(training_data)
model_directory = trainer.persist('./projects/default/')
但我无法从 rasa_nlu.training_data 中找到 load_data 函数,因此,出现以下错误:
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-5-07f2f1a6c2ac> in <module>()
----> 1 from rasa_nlu.training_data import load_data
2 from rasa_nlu.config import RasaNLUConfig
3 from rasa_nlu.model import Trainer
ImportError: cannot import name 'load_data'
有人可以帮帮我吗?