Error: ValueError: y should be a 1d array, got an array of shape (1, 4) instead

Hello everyone,

I am new to RASA, I am trying to follow the course about NLP on datacamp.

Here is my code

from rasa_nlu.converters import load_data
from rasa_nlu.config import RasaNLUConfig
from rasa_nlu.model import Trainer

args = {“pipeline”: “spacy_sklearn”}

config = RasaNLUConfig(cmdline_args=args)
trainer = Trainer(config)

training_data = load_data("./training_data.json")

interpreter = trainer.train(training_data)

Everything works fine till I call the parse method

print(interpreter.parse(“I’m looking for a Mexican restaurant in the North of town”))

I receive the error ValueError: y should be a 1d array, got an array of shape (1, 4) instead.

Please help me resolve this problem. Thanks in advance.