Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No such model: code-davinci-002 #16

Open
kwanUm opened this issue May 16, 2022 · 4 comments
Open

No such model: code-davinci-002 #16

kwanUm opened this issue May 16, 2022 · 4 comments

Comments

@kwanUm
Copy link

kwanUm commented May 16, 2022

I'm getting the error in title. org_id & secret_key are correct, but I still get the error immediately after pressing ^X.

Anyone else experiences that?

@kwanUm
Copy link
Author

kwanUm commented May 16, 2022

Traceback (most recent call last):
File "/private/home/orik/.oh-my-zsh/custom/plugins/zsh_codex/create_completion.py", line 64, in
response = openai.Completion.create(engine='code-davinci-002', prompt=prompt_prefix, suffix=prompt_suffix, temperature=0.5, max_tokens=50, stream=STREAM)
File "/private/home/orik/.conda/envs/design5_py38/lib/python3.8/site-packages/openai/api_resources/completion.py", line 31, in create
return super().create(*args, **kwargs)
File "/private/home/orik/.conda/envs/design5_py38/lib/python3.8/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 100, in create
response, _, api_key = requestor.request(
File "/private/home/orik/.conda/envs/design5_py38/lib/python3.8/site-packages/openai/api_requestor.py", line 120, in request
resp, got_stream = self._interpret_response(result, stream)
File "/private/home/orik/.conda/envs/design5_py38/lib/python3.8/site-packages/openai/api_requestor.py", line 327, in _interpret_response
self._interpret_response_line(
File "/private/home/orik/.conda/envs/design5_py38/lib/python3.8/site-packages/openai/api_requestor.py", line 360, in _interpret_response_line
raise self.handle_error_response(
openai.error.InvalidRequestError: No such model: code-davinci-002

@tom-doerr
Copy link
Owner

Do you have access to Codex? Having access to the OpenAI API is not enough.
More Info:
#15
#13

@tom-doerr tom-doerr pinned this issue May 17, 2022
@tupacalypse187
Copy link

I know this is an old issue, but I see this happening for me. I have a paid codex account setup but get the below error. Has the model changed and needs to be adjusted or is this an issue on my end? Thanks.

I'm using Hyper.js with Fig and zsh. Thank you.

# show the number of files in the current directoryTraceback (most recent call last):
  File "/Users/cyantorno/.oh-my-zsh/custom/plugins/zsh_codex/create_completion.py", line 64, in <module>
    response = openai.Completion.create(engine='code-davinci-002', prompt=prompt_prefix, suffix=prompt_suffix, temperature=0.5, max_tokens=50, stream=STREAM)
  File "/Users/cyantorno/Library/Python/3.9/lib/python/site-packages/openai/api_resources/completion.py", line 25, in create
    return super().create(*args, **kwargs)
  File "/Users/cyantorno/Library/Python/3.9/lib/python/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 153, in create
    response, _, api_key = requestor.request(
  File "/Users/cyantorno/Library/Python/3.9/lib/python/site-packages/openai/api_requestor.py", line 226, in request
    resp, got_stream = self._interpret_response(result, stream)
  File "/Users/cyantorno/Library/Python/3.9/lib/python/site-packages/openai/api_requestor.py", line 619, in _interpret_response
    self._interpret_response_line(
  File "/Users/cyantorno/Library/Python/3.9/lib/python/site-packages/openai/api_requestor.py", line 682, in _interpret_response_line
    raise self.handle_error_response(
openai.error.InvalidRequestError: The model: `code-davinci-002` does not exist

@oyale
Copy link

oyale commented Mar 27, 2023

OpenAI has discontinued code-davinci models:

On March 23rd, we will discontinue support for the Codex API. All customers will have to transition to a different model. Codex was initially introduced as a free limited beta in 2021, and has maintained that status to date. Given the advancements of our newest GPT-3.5 models for coding tasks, we will no longer be supporting Codex and encourage all customers to transition to GPT-3.5-Turbo.

On March 23rd, we will discontinue support for the Codex API. All customers will have to transition to a different model. Codex was initially introduced as a free limited beta in 2021, and has maintained that status to date. Given the advancements of our newest GPT-3.5 models for coding tasks, we will no longer be supporting Codex and encourage all customers to transition to GPT-3.5-Turbo.

Models affected
The following models will be discontinued:

code-cushman:001
code-cushman:002
code-davinci:001
code-davinci:002

We understand this transition may be temporarily inconvenient, but we are confident it will allow us to increase our investment in our latest and most capable models.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants