hello,
im using rasa 2.0
im trying to achieve the following:
accept date as text such as “in two days”, “tomorrow” , “august 15” …etc
i want to call spacy to find the DATE enteties in the text and then i use dateparses (i have issues installing duckling) to parse it and get the required date
in rasa.action validate i have written the following code
nlp = spacy.load("en_core_web_sm")
doc = nlp(slot_value)
checkin_date
is_date_found = False
for entity in doc.ents:
if entity.label_ == "DATE":
checkin_date = dp.parse(entity.text)
is_date_found - True
im getting the following error:
OSError: [E050] Can't find model 'en_core_web_sm'. It doesn't seem to be a Python package or a valid path to a data directory.
spacy must have been already loaded becuase it is configured in the pipeline but i dont know to get a reference to it, and there maybe a better way than my way but im not aware of
thank you for solutions.suggestions or better implementation ideas
Regards, Noureddine