Unable to train model in rasa Enterprise

We have installed RASA enterprise in azure kubernetes cluster using helm charts, but we are unable to train the model from UI and it fails with the below error. did anyone faced the issue and able to fix this?

ERROR:sanic.error:Exception occurred while handling uri: 'http://chat-rasa-dev.azure.cld/api/projects/default/models/jobs'
Traceback (most recent call last):
  File "handle_request", line 83, in handle_request
    )
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 265, in decorated_function
    return await await_and_return_response(args, kwargs, request)
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 193, in await_and_return_response
    response = await response
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/decorators.py", line 101, in decorated_function
    return await f(request, user=user, *args, **kwargs)
  File "/usr/local/lib/python3.8/dist-packages/rasax/community/api/blueprints/models.py", line 235, in train_model
    stack_service = stack_services[environment]
KeyError: 'worker'

@sonam Can I request the Rasa Team for an installation video (On Youtube Channel) for Rasa Enterprise with the small project? This will help the Rasa developer to get hands-on experience. Thanks.

2 Likes

Hi not sure about that, will get back.

Did you use kubernetes?

@nonola , we are deploying this azure kubernetes cluster.

I’ve been trying to install in Google GKE & it’s a nightmare. I can train with rasa OS, but on Rasa Enterprise, i cannot. With some versions it gives error when the train starts, with other versions trainning never ends…

@nonola which version of rasa enterprise and open source you are using and what are the errors that you are getting when training fails??

It’s better to do training and testing from Rasa OS and the CI/CD pipeline, not with Rasa Ent.

Does rasa data validate run without errors?

hi @stephens , data validation is completed and there is model created in local. i see the below error in the logs, did you face similar issue.

And when you say"It’s better to do training and testing from Rasa OS and the CI/CD pipeline, not with Rasa Ent." you suggest not to use enterprise installation ?

When the URL “http://hostname/api/projects/default/models/jobs” is hit directly, it returns http 403 (method not accessible)

I’m suggesting you train locally and use Rasa Ent for CDD.

thanks, @stephens , did you face the below error during training and have any suggestions on changes/configuration needs to fix this. i am getting this error when we upload traning data from entprise ui and click on Model–Train. do we need any additional setting to be done on rasa-x or rasa open soruce services after installation is done following the helm charts mentioned here. Requirements

2022-10-18 07:13:39 DEBUG rasa.core.agent - No new model found at URL http://rasa-x-1666015927-rasa-x.robochat-rasa.svc:5002/api/models/tags/production 2022-10-18 07:13:39 DEBUG rasa.engine.storage.local_model_storage - Start to created model package for path ‘models/nlu-20221018-065945-legato-interest.tar.gz’. 2022-10-18 07:13:45 DEBUG rasa.engine.storage.local_model_storage - Model package created in path ‘models/nlu-20221018-065945-legato-interest.tar.gz’. 2022-10-18 07:13:45 DEBUG urllib3.connectionpool - Starting new HTTPS connection (1): api.segment.io:443 2022-10-18 07:13:45 DEBUG urllib3.connectionpool - https://api.segment.io:443 “POST /v1/track HTTP/1.1” 200 21 2022-10-18 07:13:45 DEBUG urllib3.connectionpool - Starting new HTTPS connection (1): api.segment.io:443 2022-10-18 07:13:46 DEBUG urllib3.connectionpool - https://api.segment.io:443 “POST /v1/track HTTP/1.1” 200 21 2022-10-18 07:13:46 DEBUG rasa.server - Asynchronous processing of request was successful. Sending result to callback URL. 2022-10-18 07:13:46 ERROR asyncio - Task exception was never retrieved future: <Task finished name=‘Task-30814’ coro=<async_if_callback_url..decorated_function..wrapped() done, defined at /opt/venv/lib/python3.8/site-packages/rasa/server.py:556> exception=<InvalidURL chat-rasa-dev.azure.cld/api/projects/default/models/jobs/20/result?token=TlbY25KmjS0s4i7w9TA7> created at /opt/venv/lib/python3.8/site-packages/sanic/app.py:1565> source_traceback: Object created at (most recent call last): File “/opt/venv/bin/rasa”, line 8, in sys.exit(main()) File “/opt/venv/lib/python3.8/site-packages/rasa/main.py”, line 110, in main cmdline_arguments.func(cmdline_arguments) File “/opt/venv/lib/python3.8/site-packages/rasa/cli/x.py”, line 356, in rasa_x run_in_production(args) File “/opt/venv/lib/python3.8/site-packages/rasa/cli/x.py”, line 420, in run_in_production _rasa_service(args, endpoints, None, credentials_path) File “/opt/venv/lib/python3.8/site-packages/rasa/cli/x.py”, line 90, in _rasa_service serve_application( File “/opt/venv/lib/python3.8/site-packages/rasa/core/run.py”, line 225, in serve_application app.run( File “/opt/venv/lib/python3.8/site-packages/sanic/app.py”, line 1204, in run serve_single(server_settings) File “/opt/venv/lib/python3.8/site-packages/sanic/server/runners.py”, line 206, in serve_single serve(**server_settings) File “/opt/venv/lib/python3.8/site-packages/sanic/server/runners.py”, line 155, in serve loop.run_forever() File “connection_task”, line 15, in connection_task from sanic.http import Http, Stage File “/opt/venv/lib/python3.8/site-packages/sanic/http.py”, line 146, in http1 await self.protocol.request_handler(self.request) File “handle_request”, line 83, in handle_request ) File “/opt/venv/lib/python3.8/site-packages/rasa/server.py”, line 243, in decorated return await result if isawaitable(result) else result File “/opt/venv/lib/python3.8/site-packages/rasa/server.py”, line 585, in decorated_function request.app.add_task(wrapped()) File “/opt/venv/lib/python3.8/site-packages/sanic/app.py”, line 1609, in add_task return self._loop_add_task( File “/opt/venv/lib/python3.8/site-packages/sanic/app.py”, line 1565, in _loop_add_task task = loop.create_task(prepped, name=name) Traceback (most recent call last): File “/opt/venv/lib/python3.8/site-packages/rasa/server.py”, line 582, in wrapped await session.post(callback_url, raise_for_status=True, **payload) File “/opt/venv/lib/python3.8/site-packages/aiohttp/client.py”, line 492, in _request req = self._request_class( File “/opt/venv/lib/python3.8/site-packages/aiohttp/client_reqrep.py”, line 305, in init self.update_host(url) File “/opt/venv/lib/python3.8/site-packages/aiohttp/client_reqrep.py”, line 366, in update_host raise InvalidURL(url) aiohttp.client_exceptions.InvalidURL: chat-rasa-dev.azure.cld/api/projects/default/models/jobs/20/result?token=TlbY25KmjS0s4i7w9TA7

@koaning, can you please let know if you have any suggestions for the above errors.

Hi nik, you will have to connect with Rasa-enterprise customer solution people.

@sonam any suggested name?