lennardv2 / hey-chatgpt-cli

Hey is a powerful chatbot for the command line CLI that uses ChatGPT to generate commands based on natural language input
MIT License
41 stars 6 forks source link

Dependency versions #7

Open tm-a-t opened 7 months ago

tm-a-t commented 7 months ago

I guess setup.py misses specified version of dependencies. I installed Hey with pipx and got invalid version of open-ai library.

You tried to access openai.ChatCompletion, but this is no longer supported in openai>=1.0.0 - see the README at https://github.com/openai/openai-python for the API.

You can run `openai migrate` to automatically upgrade your codebase to use the 1.0.0 interface. 

Alternatively, you can pin your installation to the old version, e.g. `pip install openai==0.28`

Manual installation helped:

pipx inject hey-gpt openai==0.28

By the way, the project looks awesome.

Dulani commented 1 month ago

The comment above helped, though I needed --force to finish the job:

$ pipx inject hey-gpt openai==0.28
⚠️ openai already seems to be injected in 'hey-gpt'. Not modifying existing installation in
'<homedir>/.local/share/pipx/venvs/hey-gpt'. Pass '--force' to force installation.
$ pipx inject --force hey-gpt openai==0.28
  injected package openai into venv hey-gpt
done!