karthink / gptel

A simple LLM client for Emacs
GNU General Public License v3.0
1.14k stars 119 forks source link

Incorrect Model Requested #43

Closed fosskers closed 1 year ago

fosskers commented 1 year ago

I got requests working, and decided to ask GPT who it was:

*** Are you GPT4?

As of my current programming, there is no such thing as GPT-4 yet. The most advanced version of OpenAI's GPT (Generative Pretrained Transformer) series is currently GPT-3, which I am built upon.

Even though I have gptel-model set to "gpt-4". I debugged the request and got:

HTTP/2 200 
date: Thu, 13 Apr 2023 04:36:44 GMT
content-type: text/event-stream
access-control-allow-origin: *
cache-control: no-cache, must-revalidate
openai-model: gpt-3.5-turbo-0301
openai-organization: user-qjkgvih2ozde13ryzoiwm7t3
openai-processing-ms: 348
openai-version: 2020-10-01
strict-transport-security: max-age=15724800; includeSubDomains
x-ratelimit-limit-requests: 3500
x-ratelimit-remaining-requests: 3499
x-ratelimit-reset-requests: 17ms
x-request-id: 20bc2c2c51b1dd2d503035a274b95064
cf-cache-status: DYNAMIC
server: cloudflare
cf-ray: 7b71027dc802e005-NRT
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400

Notice the openai-model field.

fosskers commented 1 year ago

Further, from a fresh Emacs session, setting the gptel-model variable in config is not respected. I have it set to "gpt-4", but a new gptel invocation always starts with gpt-3.5-turbo with the value of gpt-model that I set myself overwritten.

fosskers commented 1 year ago

Further again, even after evaluating (setq gptel-model "gpt-4") in the chat buffer itself it still calls the API via 3.5 turbo.

karthink commented 1 year ago

Oops, thanks for catching that! Fixed in 444a4313.

karthink commented 1 year ago

Didn't mean to close this issue yet. Did Github auto-close this because I said it's fixed in my above message?

karthink commented 1 year ago

@fosskers I take it from the reaction this is fixed now. Feel free to reopen this issue if not.

fosskers commented 1 year ago

Uh oh...

HTTP/2 404 
date: Thu, 13 Apr 2023 05:37:31 GMT
content-type: application/json; charset=utf-8
vary: Origin
x-request-id: ac70f63f6b5951daddce9b5c16271406
strict-transport-security: max-age=15724800; includeSubDomains
cf-cache-status: DYNAMIC
server: cloudflare
cf-ray: 7b715b885cc2af5a-NRT
content-encoding: gzip
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400

{
    "error": {
        "message": "The model: `gpt-4` does not exist",
        "type": "invalid_request_error",
        "param": null,
        "code": "model_not_found"
    }
}
fosskers commented 1 year ago

The consensus here seems to be that this is an issue on OpenAI's end; mainly that my account might not have GPT-4 access yet.