You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Don't know if it's a bug, but I'm trying to make Sentiment Analysis using OpenAI GPT-4. I was trying to do so using the completions API with the example of the documentation.
response=client.completions(parameters: {model: "gpt-4o",prompt: "Once upon a time",max_tokens: 5})
But I get this error:
OpenAI HTTP Error (spotted in ruby-openai 7.3.1): {"error"=>{"message"=>"This is a chat model and not supported in the v1/completions endpoint. Did you mean to use v1/chat/completions?", "type"=>"invalid_request_error", "param"=>"model", "code"=>nil}}
With GPT3.5 too
response=client.chat.completions(parameters: {model: "gpt-3.5-turbo-0125",prompt: "Once upon a time",max_tokens: 5})
OpenAI HTTP Error (spotted in ruby-openai 7.3.1): {"error"=>{"message"=>"you must provide a model parameter", "type"=>"invalid_request_error", "param"=>nil, "code"=>nil}}
To Reproduce
Steps to reproduce the behavior:
Enter in a Ruby console
Use the code above
Expected behavior
Just receive the response from Chat GPT.
Desktop (please complete the following information):
OS: Ubuntu 20.04.6 LTS
Additional context
Ruby: 3.3.6
Rails: 7.2.2
Ruby-OpenAI: 7.3.1
The text was updated successfully, but these errors were encountered:
The completions models are now considered legacy. The /v1/completions endpoint is still present, however, you must use a compatible model to access them:
Describe the bug
Don't know if it's a bug, but I'm trying to make Sentiment Analysis using OpenAI GPT-4. I was trying to do so using the completions API with the example of the documentation.
But I get this error:
With GPT3.5 too
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Just receive the response from Chat GPT.
Desktop (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: