CrewAI OpenAI issue

I cannot run the first notebook, I also get the same error when running crew “result = crew.kickoff(inputs={“topic”: “Artificial Intelligence”})”:

PermissionDeniedError Traceback (most recent call last)
Cell In[12], line 1
----> 1 result = crew.kickoff(inputs={“topic”: “Artificial Intelligence”})

File ~/.local/lib/python3.11/site-packages/openai/_base_client.py:1020, in SyncAPIClient._request(self, cast_to, options, remaining_retries, stream, stream_cls)
1017 err.response.read()
1019 log.debug(“Re-raising status error”)
→ 1020 raise self._make_status_error_from_response(err.response) from None
1022 return self._process_response(
1023 cast_to=cast_to,
1024 options=options,
(…)
1027 stream_cls=stream_cls,
1028 )

PermissionDeniedError:

Forbidden (403)
<link rel="icon" href="/static/images/favicons/favicon.a66bc42b4e8a.ico">


<!-- Latest compiled and minified Bootstrap CSS -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.1.3/css/bootstrap.min.css" integrity="sha512-GQGU0fMMi238uA+a/bdWJfpUGKUkBdgfFdgBm72SUQ6BeyWjoY/ton0tEjH+OSH9iP4Dfh+7HM0I9f5eR0L/4w==" crossorigin="anonymous" referrerpolicy="no-referrer" />
<!-- Your stuff: Third-party CSS libraries go here -->

<!-- This file stores project-specific CSS -->
<link href="/static/css/project.a9bf09099778.css" rel="stylesheet">

<!-- Le javascript
================================================== -->


  <!-- Bootstrap JS -->
  <script defer src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.1.3/js/bootstrap.min.js" integrity="sha512-OvBgP9A2JBgiRad/mM36mkzXSXaJE9BEIENnVEmeZdITvwT09xnxLtT4twkCa8m/loMbPHsvPl0T8lRGVBwjlQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  <!-- Your stuff: Third-party javascript libraries go here -->

  <!-- place project specific Javascript in this file -->
  <script defer src="/static/js/project.e8c1a24dd152.js"></script>
<div class="container">

Forbidden (403)

You're not allowed to access this page.

</div> <!-- /container -->

Hi @doxa,

Are you running the notebook locally or on the platform?

Thanks,
Mubsi

I am running on the platform. This seems to be related to OpenAI API restrictions. I tried to put my own OpenAI key but had the same problem. I found a workaround which is to use another account on deeplearning.ai. This is bad because I can no more use my account.

Hi @doxa,

When using your own key, I’d recommend to run the notebook locally.

The platform has certain “checks” regarding the API hits, which is why you are not able to use your own key there.

Best,
Mubsi

I tried many times online without changing anything, letting default DL.AI default API key, but I always add this error. I then tried to use my own OpenAPI key to check if the error was caused by the provided key, it didn’t solve the problem. In The only solution is to use another account. It seems to me that deeplearning.ai has also openai usage checks based on users which can definitly block following a course once there is something wrong ?