ChatGPT icon indicating copy to clipboard operation
ChatGPT copied to clipboard

InvalidRequestError: That model does not exist

Open acheong08 opened this issue 2 years ago • 31 comments

#517 #523 #532

acheong08 avatar Feb 03 '23 02:02 acheong08

@acheong08 FYI If you add them in a list, GitHub will auto-expand to show all the titles. Makes it nicer to see/read:

  • https://github.com/acheong08/ChatGPT/issues/517
  • https://github.com/acheong08/ChatGPT/issues/523
  • https://github.com/acheong08/ChatGPT/issues/532
  • https://github.com/acheong08/ChatGPT/issues/530

0xdevalias avatar Feb 03 '23 02:02 0xdevalias

Thanks

acheong08 avatar Feb 03 '23 02:02 acheong08

Anyone with Azure's OpenAI service might be able to find the new model name.

Refer to

  • https://learn.microsoft.com/en-us/rest/api/cognitiveservices/azureopenaistable/models/list?tabs=HTTP

acheong08 avatar Feb 03 '23 02:02 acheong08

@acheong08 https://github.com/waylaidwanderer/node-chatgpt-api/issues/19#issuecomment-1414759800

khanhphxm avatar Feb 03 '23 03:02 khanhphxm

Found without access to Azure's OpenAI

import openai
import concurrent.futures

from revChatGPT.Official import Chatbot

defaultModel = "text-chat-davinci-002-XXXXXXXX"
successfulModels = []

def test_model(model):
    try:
        bot = Chatbot(api_key="", engine=model)
        response = bot.ask("what is the capitol of the unitd states of america?")
        if response:
            successfulModels.append(model)
    except openai.InvalidRequestError:
        print("Model [" + model + "] failed to load. (Invalid Request Error)")

with concurrent.futures.ThreadPoolExecutor(max_workers=16) as executor:
    for year in range(2020, 2031):
        for month in range(1, 13):
            for day in range(1, 32):
                formatted_year = "{:04d}".format(year)
                formatted_month = "{:02d}".format(month)
                formatted_day = "{:02d}".format(day)
                model = defaultModel.replace("XXXXXXXX", formatted_year + formatted_month + formatted_day)
                executor.submit(test_model, model)

print("Successful Models: " + str(successfulModels))

Slightly modified the module to take in a "model" property

khanhphxm avatar Feb 03 '23 03:02 khanhphxm

Oh nice. I didn't think to look at older dates when I was brute forcing

acheong08 avatar Feb 03 '23 03:02 acheong08

https://github.com/acheong08/ChatGPT/releases/tag/1.1.1

acheong08 avatar Feb 03 '23 03:02 acheong08

Successful Models: []

Liu-Angelo avatar Feb 03 '23 03:02 Liu-Angelo

super active community. thanks @acheong08!!!

DanPen avatar Feb 03 '23 04:02 DanPen

@canfam man!!!! you are soooooo smart!!! thankS! thank you!!!!!!!!

HelloWorldWinning avatar Feb 03 '23 05:02 HelloWorldWinning

https://github.com/acheong08/ChatGPT/releases/tag/1.1.1

offical version if the interface is encapsulated how to control the context?

Liu-Angelo avatar Feb 03 '23 07:02 Liu-Angelo

offical version if the interface is encapsulated how to control the context?

Conversations and stuff are stored locally (in memory or file)

You can take a read through the code to see how that was done (in the main function)

acheong08 avatar Feb 03 '23 09:02 acheong08

I'll need some time to document

acheong08 avatar Feb 03 '23 09:02 acheong08

Can you confirm if it works now, and if it uses credit?

Strachi-sama avatar Feb 03 '23 12:02 Strachi-sama

Confirmed it works and doesn't use credit on an account with $0. It still charges the same amount as davinci on account with $

acheong08 avatar Feb 03 '23 12:02 acheong08

@acheong08 Awsome!

hunkim avatar Feb 04 '23 01:02 hunkim

Are you saying it still has the same date and just different name?

I already said that in discord Yeah the new model has the same date with a new name, its looks like just renamed not removed

I've just been playing around with updating some of my scripts/research/etc in my PoC ChatGPT repo this morning:

  • https://github.com/0xdevalias/poc-chatgpt
    • https://github.com/0xdevalias/poc-chatgpt/commits/main

And if you look at this commit, you can see that when I extracted/sorted the output of /v1/models by created date, there is one at the top which curiously seems to share a date (20230126) with the original leaked model (text-chat-davinci-002-20230126):

2023-01-26T23:36:25Z audio-transcribe-deprecated

Though if I try and use it with the completions API, I get an error:

⇒ curl https://api.openai.com/v1/completions -H 'Content-Type: application/json' -H "Authorization: Bearer $OPENAI_API_KEY" -d '{
  "model": "audio-transcribe-deprecated",
  "prompt": "Say this is a test",
  "max_tokens": 7,
  "temperature": 0
}'

{
  "error": {
    "message": "The server had an error processing your request. Sorry about that! You can retry your request, or contact [email protected] if you keep seeing this error. (Please include the request ID 316fc3215fa0a3278824c35138d3665a in your email.)",
    "type": "server_error",
    "param": null,
    "code": null
  }
}

Could be a coincidence.. but figured I would include the info here in case it's helpful to anyone.

Originally posted by @0xdevalias in https://github.com/acheong08/ChatGPT/issues/517#issuecomment-1416911061

0xdevalias avatar Feb 05 '23 03:02 0xdevalias

The error is back, "That model does not exist"

mo29cg avatar Feb 06 '23 08:02 mo29cg

You're using the wrong model

The error is back, "That model does not exist"

acheong08 avatar Feb 06 '23 08:02 acheong08

text-chat-davinci-002-20221122

acheong08 avatar Feb 06 '23 08:02 acheong08

Remember to upgrade

acheong08 avatar Feb 06 '23 08:02 acheong08

sorry, if I'm being dumby. but how do you upgrade it? should I manually modify, "model": "text-davinci-002-render in ChatGPT.py to the model name you posted?, I tryied it, but it didn't work.

mo29cg avatar Feb 06 '23 09:02 mo29cg

You're on the wrong file

acheong08 avatar Feb 06 '23 09:02 acheong08

Please read the README for usage. You are meant to be using revChatGPT.Official

Example usage: https://github.com/acheong08/ChatGPT/blob/be9307d72d1d0baf86d757950edf0bd3648a5d4d/src/revChatGPT/main.py#L1-L123

acheong08 avatar Feb 06 '23 09:02 acheong08

Thank you so much, I modified Official.py, it is working now!

mo29cg avatar Feb 06 '23 09:02 mo29cg

My account was banned after frequently using the official API. Getting message "openai.error.RateLimitError: Your access was terminated due to violation of our policies, please check your email for more information. If you believe this is in error and would like to appeal, please contact [email protected]."

Is there a hard limit on how many requests we can send to the model before the account gets banned?

reveching avatar Feb 07 '23 03:02 reveching

This is new. You seem to be the first one affected. Were you generating any NSFW or disinformation against their TOS?

acheong08 avatar Feb 07 '23 04:02 acheong08

Do you mind sharing the suspended API key? I would like to document the JSON error message

Or maybe can you share the response from the completions endpoint when suspended?

acheong08 avatar Feb 07 '23 04:02 acheong08

API key: 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

I was asking the model to generate the prompts that were used to train ChatGPT and I think this might be the reason for breaking TOS.

reveching avatar Feb 07 '23 04:02 reveching

Interesting fact: The second you share an API key on GitHub, it is instantly revoked.

The cooperation between OpenAI and Microsoft runs deep

acheong08 avatar Feb 07 '23 04:02 acheong08