[go: nahoru, domu]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'OpenAI' from 'openai' (/usr/local/lib/python3.10/dist-packages/openai/__init__.py) #20

Closed
VictoryBlue opened this issue Feb 23, 2024 · 1 comment

Comments

@VictoryBlue
Copy link

/content/RankGPT/rank_gpt.py in init(self, keys, start_id, proxy)
7 class OpenaiClient:
8 def init(self, keys=None, start_id=None, proxy=None):
----> 9 from openai import OpenAI
10 import openai
11 if isinstance(keys, str):

ImportError: cannot import name 'OpenAI' from 'openai' (/usr/local/lib/python3.10/dist-packages/openai/init.py)

@sunnweiwei
Copy link
Owner

You could try upgrading openai: pip install -U openai

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants