momaabna/QGPTAgent

Key Error

Opened this issue · 5 comments

I am getting a KeyError: 'choices' error when I send off a request. This is for both Chat as well as Agent mode.
What am I supposed to enter under User Name in the Settings?
plugins\qgpt_agent_release\qgpt_agent_dockwidget.py", line 90, in get_completion
completion = response.json()['choices'][0]['text']
KeyError: 'choices'

Apparently, that is because the plugin cannot connect to Openai API,
Update to the last version
Check

  • Internet Connection
  • OpenAI API Key
  • Your Balance In OpenAI Account

Check this tutorial that shows the installation process

https://www.youtube.com/watch?v=OkYSWwpduiw

If the error still exists submit it here
witing to hear from you

Have You clicked set token button in setting tab ?

The user name is only to show in the chat box nothing more.