At the moment my model gives 3 output tensors. I want two of them to be more cooperative. I want to use the combination of self.dropout1(hs) and self.dropout2(cls_hs) to pass through the self.entity_out Linear Layer. The issue is mentioned 2 tensors are in different shapes. Current Code class NLUModel(nn.Module): def __init__(self, num_entity, num_intent, num_scenarios): super(NLUModel, ..
I’m trying to make a NLU model. When I run from rasa_nlu.config import RasaNLUConfig I get an error: ImportError Traceback (most recent call last) <ipython-input-1-c2bca1b53b6f> in <module> —-> 1 from rasa_nlu.config import RasaNLUConfig 2 from rasa_nlu.model import Trainer ImportError: cannot import name ‘RasaNLUConfig’ from ‘rasa_nlu.config’ (/usr/local/lib/python3.7/dist-packages/rasa_nlu/config.py) I thought, "Meh,not a big issue, Colaboratory just hasn’t ..
I need to get the headwords of sentences based on Nominal group structure. In order to determine the pre and post position of the word. For example; Those two splendid old electric trains with ….. The head | root is: trains Source: Python..
I am trying to use the NLU library in google colab. I am doing text classification and I am just testing the nlu, loading the bert model and predicting a sentence’s sentiment. However, I can’t make it work and I haven’t found any solution online yet. It appears that in both parts there is an ..
I am working on Watson NLU and I need to run analysis on questionnaire data. About 300 answers from separate people. I am able to run it on "…" format text, but I’d love to get some help on how I can run it for all the 300 in one run. My current input is ..
I have using DIETClassifier for my entity extraction, and this is my pipeline: pipeline: – name: SpacyNLP model: en_core_web_sm – name: SpacyTokenizer – name: CountVectorsFeaturizer – name: CRFEntityExtractor – name: DIETClassifier epochs: 200 random_seed: 2 and this is example of intents that I have with entities in the nlu file: version: "2.0" nlu: – intent: ..
I have an old code in python which uses different sklearn algorithms to predict the intent of a sentence. It uses tfidf to preprocess the data and with Logistic Regression, Multinomial NB, Linear SVC and Bernouilli Naive Bayes it calculates the probability of the sentence to belong to one of the four clases that the ..
I am getting this error when I try to run a line of the nlu package provided in its documentation: import nlu nlu.load(‘ner’).predict(‘Angela Merkel from Germany and the American Donald Trump dont share many opinions’) ————————————————————————— Py4JError Traceback (most recent call last) <ipython-input-3-eb1d63b68bdb> in <module> —-> 1 nlu.load(‘ner’).predict(‘Angela Merkel from Germany and the American Donald ..