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

Request to Update OpenAI Implementation to Support New API Schema #71

Open
nikolas-rauscher opened this issue Mar 1, 2024 · 1 comment · Fixed by nikolas-rauscher/semantra-#1 · May be fixed by #78
Open

Request to Update OpenAI Implementation to Support New API Schema #71

nikolas-rauscher opened this issue Mar 1, 2024 · 1 comment · Fixed by nikolas-rauscher/semantra-#1 · May be fixed by #78

Comments

@nikolas-rauscher
Copy link

I have encountered an issue related to the OpenAI model. The problem arises because the current implementation relies on the outdated OpenAI API schema, which is not supported in versions of the openai library greater than 1.0.0.

The recent versions of the OpenAI API have deprecated the openai.Embedding interface, which the code currently relies on. This results in the following error when attempting to use the feature:

You tried to access openai.Embedding, 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`

A detailed migration guide is available here: https://github.com/openai/openai-python/discussions/742

Are there plans to update this?

@yych42
Copy link
Contributor

yych42 commented Mar 1, 2024

I was planning to implement text-embedding-3 support this weekend, so I’ll take a look at this too.

nikolas-rauscher added a commit to nikolas-rauscher/semantra- that referenced this issue Mar 1, 2024
nikolas-rauscher added a commit to nikolas-rauscher/semantra- that referenced this issue Mar 1, 2024
@yych42 yych42 linked a pull request May 21, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants