Dependence errors

Hi,

I am trying to run financial bot demo . While installing I am getting spacy installation issues. Which spacy version is compatible with rasa?

Issues:

Rasa version:

Rasa Version:         2.6.3
Minimum Compatible Version: 2.6.0
Rasa SDK Version:         2.6.0
Rasa X Version:         None
Python Version:         3.8.11

Would help me out with this issue

Thanks in advance

@manoj_kumar I’d encourage go with the latest I guess 2.8.1 or 2.8.2 for rasa and rasa-sdk respectively and then try to install spaCy

pip3 install rasa[spacy]
python3 -m spacy download en_core_web_md

If you still face some issues do share the screenshot.

Hi @nik202

I am getting an issue while checking the rasa --version mentioned below.

@manoj_kumar activate your conda environment and then try, you are in base.

I have all the dependencies in the “base” only and I resolved it and another issue while running the rasa action server getting a few warnings and can’t able open rasa x.

Rasa action window →

While starting the Rasa x getting the below-mentioned issue -

Sorry, something went wrong (see error above). Make sure to start Rasa X with valid data and valid domain and config files. Please, also check any warnings that popped up.
If you need help fixing the issue visit our forum: http://forum.rasa.com/.

@manoj_kumar The approach you adopting is not right, you need to create the condo virtual environment and then need to install rasa and rasa-x, else what ever you update, it will directly effect your base. I hope you understand my point.

Yes, @nik202 I have a trained model and while trying to train again it is not getting trained.

<frozen importlib._bootstrap>:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144 from C header, got 152 from PyObject
<frozen importlib._bootstrap>:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144 from C header, got 152 from PyObject
<frozen importlib._bootstrap>:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144 from C header, got 152 from PyObject
<frozen importlib._bootstrap>:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144 from C header, got 152 from PyObject
2021-08-06 18:57:30 INFO     rasa.shared.utils.validation  - The 'version' key is missing in the training data file C:\Users\AppsTek V1\Code\financial-demo-rasa-2-0\domain.yml. Rasa Open Source will read the file as a version '2.0' file. See https://rasa.com/docs/rasa/training-data-format.
2021-08-06 18:57:32 INFO     rasa.model  - Data (config) for Core model section changed.
2021-08-06 18:57:32 INFO     rasa.model  - Data (config) for NLU model section changed.
2021-08-06 18:57:32 INFO     rasa.model  - Data (nlg) for NLG templates section changed.
Training NLU model...
2021-08-06 18:57:43 INFO     rasa.nlu.utils.spacy_utils  - Trying to load spacy model with name 'en_core_web_md'
2021-08-06 18:57:58 INFO     rasa.nlu.components  - Added 'SpacyNLP' to component cache. Key 'SpacyNLP-en_core_web_md'.
2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  - Training data stats:
2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  - Number of intent examples: 374 (20 distinct intents)

2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  -   Found intents: 'inform', 'affrim', 'pay_cc', 'trigger_handoff', 'search_transactions', 'ask_transfer_charge', 'check_creditscore', 'goodbye', 'check_earnings', 'affirm', 'handoff', 'help', 'human_handoff', 'out_of_scope', 'check_recipients', 'greet', 'thankyou', 'transfer_money', 'deny', 'check_balance'
2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  - Number of response examples: 0 (0 distinct responses)
2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  - Number of entity examples: 183 (5 distinct entities)
2021-08-06 18:57:58 INFO     rasa.shared.nlu.training_data.training_data  -   Found entity types: 'account_type', 'PERSON', 'amount-of-money', 'credit_card', 'vendor_name'
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Intent 'affrim' has only 1 training examples! Minimum is 2, training may fail.
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Intent 'handoff' has only 1 training examples! Minimum is 2, training may fail.
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Intent 'trigger_handoff' has only 1 training examples! Minimum is 2, training may fail.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component WhitespaceTokenizer
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Finished training component.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component RegexFeaturizer
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Finished training component.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component LexicalSyntacticFeaturizer
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Finished training component.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component CountVectorsFeaturizer
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Finished training component.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component CountVectorsFeaturizer
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Finished training component.
2021-08-06 18:57:58 INFO     rasa.nlu.model  - Starting to train component DIETClassifier
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\classifiers\diet_classifier.py:656: VisibleDeprecationWarning: Creating an ndarray from ragged nested sequences (which is a list-or-tuple of lists-or-tuples-or ndarrays with different lengths or shapes) is deprecated. If you meant to do this, you must specify 'dtype=object' when creating the ndarray.
  model_data.add_features(key, sub_key, [np.array(_features)])
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'what's my credit card account balance?' with intent 'check_balance'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'What's my a/c/c balance?' with intent 'check_balance'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'my acc balance' with intent 'check_balance'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'my acc.acccc. balance' with intent 'check_balance'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'my amount in account' with intent 'check_balance'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'check my credit score ' with intent 'check_creditscore'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
c:\users\appstek v1\anaconda3\lib\site-packages\rasa\shared\utils\io.py:93: UserWarning: Misaligned entity annotation in message 'check my cibilcibil score' with intent 'check_creditscore'. Make sure the start and end values of entities in the training data match the token boundaries (e.g. entities don't include trailing whitespaces or punctuation).
  More info at https://rasa.com/docs/rasa/training-data-format#nlu-training-data
Traceback (most recent call last):
  File "c:\users\appstek v1\anaconda3\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\users\appstek v1\anaconda3\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Users\AppsTek V1\anaconda3\Scripts\rasa.exe\__main__.py", line 7, in <module>
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\__main__.py", line 116, in main
    cmdline_arguments.func(cmdline_arguments)
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\cli\train.py", line 81, in train
    return rasa.train(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\train.py", line 43, in train
    return rasa.utils.common.run_in_loop(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\utils\common.py", line 308, in run_in_loop
    result = loop.run_until_complete(f)
  File "c:\users\appstek v1\anaconda3\lib\asyncio\base_events.py", line 616, in run_until_complete
    return future.result()
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\train.py", line 102, in train_async
    return await _train_async_internal(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\train.py", line 198, in _train_async_internal
    await _do_training(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\train.py", line 240, in _do_training
    model_path = await _train_nlu_with_validated_data(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\train.py", line 541, in _train_nlu_with_validated_data
    await rasa.nlu.train(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\train.py", line 114, in train
    interpreter = trainer.train(training_data, **kwargs)
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\model.py", line 204, in train
    updates = component.train(working_data, self.config, **context)
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\classifiers\diet_classifier.py", line 771, in train
    self.model.fit(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\utils\tensorflow\models.py", line 184, in fit
    ) = self._get_tf_train_functions(eager, model_data, batch_strategy)
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\utils\tensorflow\models.py", line 425, in _get_tf_train_functions
    self._get_tf_call_model_function(
  File "c:\users\appstek v1\anaconda3\lib\site-packages\rasa\utils\tensorflow\models.py", line 408, in _get_tf_call_model_function
    tf_call_model_function(next(iter(init_dataset)))
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\def_function.py", line 780, in __call__
    result = self._call(*args, **kwds)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\def_function.py", line 823, in _call
    self._initialize(args, kwds, add_initializers_to=initializers)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\def_function.py", line 696, in _initialize
    self._stateful_fn._get_concrete_function_internal_garbage_collected(  # pylint: disable=protected-access
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\function.py", line 2855, in _get_concrete_function_internal_garbage_collected
    graph_function, _, _ = self._maybe_define_function(args, kwargs)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\function.py", line 3213, in _maybe_define_function
    graph_function = self._create_graph_function(args, kwargs)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\function.py", line 3065, in _create_graph_function
    func_graph_module.func_graph_from_py_func(
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\framework\func_graph.py", line 986, in func_graph_from_py_func
    func_outputs = python_func(*func_args, **func_kwargs)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\eager\def_function.py", line 600, in wrapped_fn
    return weak_wrapped_fn().__wrapped__(*args, **kwds)
  File "C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\framework\func_graph.py", line 973, in wrapper
    raise e.ag_error_metadata.to_exception(e)
NotImplementedError: in user code:

    c:\users\appstek v1\anaconda3\lib\site-packages\rasa\utils\tensorflow\models.py:257 train_on_batch  *
        prediction_loss = self.batch_loss(batch_in)
    c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\classifiers\diet_classifier.py:1608 batch_loss  *
        sequence_lengths = self._get_sequence_lengths(
    c:\users\appstek v1\anaconda3\lib\site-packages\rasa\nlu\classifiers\diet_classifier.py:1588 _get_sequence_lengths  *
        sequence_lengths = tf.ones([batch_dim], dtype=tf.int32)
    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\util\dispatch.py:201 wrapper  **
        return target(*args, **kwargs)
    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\ops\array_ops.py:3041 ones
        output = _constant_if_small(one, shape, dtype, name)
    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\ops\array_ops.py:2732 _constant_if_small
        if np.prod(shape) < 1000:
    <__array_function__ internals>:5 prod

    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\numpy\core\fromnumeric.py:3051 prod
        return _wrapreduction(a, np.multiply, 'prod', axis, dtype, out,
    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\numpy\core\fromnumeric.py:86 _wrapreduction
        return ufunc.reduce(obj, axis, dtype, out, **passkwargs)
    C:\Users\AppsTek V1\AppData\Roaming\Python\Python38\site-packages\tensorflow\python\framework\ops.py:845 __array__
        raise NotImplementedError(

    NotImplementedError: Cannot convert a symbolic Tensor (strided_slice_6:0) to a numpy array. This error may indicate that you're trying to pass a Tensor to a NumPy call, which is not supported

Okay, should I uninstall Rasa and Rasa-x in the base

@manoj_kumar No, you just need to create conda environment, check my solution threads you will find the completed installation steps.

Or check this

Okay @nik202 and thank you. Will try implementing the steps.

Getting Issue for rasa x.

Traceback (most recent call last):
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\runpy.py", line 192, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\AppsTek V1\anaconda3\envs\rasa_env\Scripts\rasa.exe\__main__.py", line 7, in <module>
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasa\__main__.py", line 117, in main
    cmdline_arguments.func(cmdline_arguments)
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasa\cli\x.py", line 354, in rasa_x
    run_locally(args)
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasa\cli\x.py", line 469, in run_locally
    from rasax.community import local
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasax\community\local.py", line 19, in <module>
    from rasax.community import telemetry, sql_migrations, scheduler, global_state
  File "c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasax\community\sql_migrations.py", line 6, in <module>
    from alembic import command
ImportError: cannot import name 'command' from 'alembic' (unknown location)

@manoj_kumar share rasa --version

Rasa Version     : 2.0.2
Rasa SDK Version : 2.1.2
Rasa X Version   : 0.33.2
Python Version   : 3.8.0
Operating System : Windows-10-10.0.19041-SP0

According to requirement.txt file, I have install the rasa version as mentioned above. After installing all the dependencies I am getiing an error with rasa x.

Sorry, something went wrong (see error above). Make sure to start Rasa X with valid data and valid domain and config files. Please, also check any warnings that popped up. If you need help fixing the issue visit our forum: http://forum.rasa.com/.

requirements.txt (71 Bytes)

@manoj_kumar update rasa and rasa-sdk to 2.8.1 and rasa-x to 0.39.3

While training on the rasa 2.8.1 version I am getting the warning that

c:\users\appstek v1\anaconda3\envs\rasa_env\lib\site-packages\rasa\shared\core\domain.py:1999: FutureWarning: The definition of slot mappings in your form should always be preceded by the keyword `required_slots`. The lack of this keyword will be deprecated in Rasa Open Source 3.0.0. Please see https://rasa.com/docs/rasa/forms for more information.
  rasa.shared.utils.io.raise_deprecation_warning(

@manoj_kumar I guess is just a warning, or check what this warning suggesting for slot mapping and required_slots, do this warning effecting your bot process?

Thanks @nik202

Got a solution for this Dependence errors - #13 by manoj_kumar

try to remove rasa.db and event.db in the project file and run rasa x

It works for me.

Fail to run rasa x in local mode - #6 by nik202 :slight_smile: