MaxSSD / OpenAI-GUI

Graphical user interface (GUI) for interacting with various OpenAI models. With this GUI, you can easily run various language and machine learning models, such as GPT-3 and DALL-E, without needing to use the command line.
MIT License
31 stars 8 forks source link

Are truncated results expected? #7

Open PySimpleGUI opened 1 year ago

PySimpleGUI commented 1 year ago

I've noticed that long answers get cut off. Is this a limitation of the OpenAI SDK or is there a bug in the code somewhere?

MaxSSD commented 1 year ago

I am getting multiple different errors across python and javas recently, maybe something is cooking with the api.

openai.error.ServiceUnavailableError: The server is overloaded or not ready yet.

ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host

requests.exceptions.ConnectionError: ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))

MaxSSD commented 1 year ago

I removed the slider which was causing the issue, but now the requested token number is always 1 higher than the required number.

openai.error.InvalidRequestError: This model's maximum context length is 4097 tokens, however you requested 4098 tokens (11 in your prompt; 4087 for the completion). Please reduce your prompt; or completion length.

PySimpleGUI commented 1 year ago

I'm still running an older version... one that I posted here in an issue, so I don't have a slider. This is basically the same as the original. The text written to answers.txt is also truncated. I've not used the program for image, only text. Maybe I should simlify things way down to just the text portion.