Closed AXIOM-XD closed 1 year ago
I had a working ChatGPT by using this package, but today I have run pip install git+https://github.com/mmabrouk/chatgpt-wrapper
to update dependency and try GPT-4
inside Emacs. Now I'm having the same issue: ERROR: nil
on every request. Looks like that dependency has a breaking change. Thus latest https://github.com/mmabrouk/chatgpt-wrapper
is not compatible with current ChatGPT.el.
These changes fixed the issue:
modified .emacs.d/user/ChatGPT.el/chatgpt.py
@@ -12,7 +12,9 @@ def query(query):
global bot
if bot == None:
bot = ChatGPT()
- return bot.ask(query)
+ bot.agpt.model = 'gpt4' # This is to try GPT-4, unrelated to the issue and requires ChatGPT Plus
+ success, response, message = bot.ask(query)
+ return response
server.print_port()
server.serve_forever()
Good fix! I got the same error, and it seems the new chatGPT-wrapper(0.6.3) returns a list instead of a string.
from epc.client import EPCClient
client = EPCClient(('localhost', <port_number>))
# query_func = client.call_sync
query = 'Hello, how are you?'
response = client.call_sync('query', [query])
print(response)
[True, "Hello! As an artificial intelligence language model, I don't have emotions, but I'm functioning properly and ready to assist you with any questions or concerns you may have. How can I assist you today?", 'Response received']
I had a working ChatGPT by using this package, but today I have run
pip install git+https://github.com/mmabrouk/chatgpt-wrapper
to update dependency and tryGPT-4
inside Emacs. Now I'm having the same issue:ERROR: nil
on every request. Looks like that dependency has a breaking change. Thus latesthttps://github.com/mmabrouk/chatgpt-wrapper
is not compatible with current ChatGPT.el.
Yes, I found the breaking change since chatgpt-wrapper 0.5.0.
ChatGPT
/AsyncChatGPT
classes have changed, they are now tuple with the following values:
Most likely addressed in https://github.com/joshcho/ChatGPT.el/commit/c38c9150b4f156c90c44f330aa0cd2497d66f8c5
I have done everything like the instruction says. But when i try to execute a query with C-c q it says "ERROR: nil" in the chat buffer.
I tried to "pkill ms-playwright/firefox" and also "pkill ms-playwright/firefox && chatgpt install" but it did not worked out at all. I still have the same error.
I use Arch Linux. I tried to install all the needed packages with pip but then i had some problems with the path variable. It could not find the executables. So i uninstalled everything and then installed everything with "makepkg -si" from the Arch User Repository. The variables/paths are well now and i can use chatgpt in my cli but not in emacs.
What can i do?