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

Upgrade openai sdk to v.1.2.3 #171

Merged
merged 16 commits into from
Nov 15, 2023

Conversation

acatav
Copy link
Contributor

@acatav acatav commented Nov 14, 2023

Problem

Canopy is not compatible to new major version change in OpenAI sdk

Solution

Make Canopy compatible with the new sdk version. Canopy is very new so this PR remove the backwards compatibility

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update
  • Infrastructure change (CI configs, etc)
  • Non-code change (docs, etc)
  • None of the above: (explain here)

Test Plan

Adding tests before making it a PR

Copy link
Collaborator

@igiloh-pinecone igiloh-pinecone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@acatav Please read the comments, then maybe let's do a quick sync to discuss?

src/canopy/knowledge_base/record_encoder/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Show resolved Hide resolved
src/canopy/models/data_models.py Outdated Show resolved Hide resolved
src/canopy/models/data_models.py Outdated Show resolved Hide resolved
src/canopy/llm/openai.py Outdated Show resolved Hide resolved
@acatav acatav marked this pull request as ready for review November 15, 2023 11:45
pyproject.toml Outdated Show resolved Hide resolved
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing changes:

  1. Change the notebook
  2. Change the library readme
  3. Verify CLI
  4. In the config file, add example of model params (commented out, see index_params in KB)

Copy link
Collaborator

@igiloh-pinecone igiloh-pinecone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few comments

src/canopy/chat_engine/chat_engine.py Show resolved Hide resolved
src/canopy/llm/base.py Show resolved Hide resolved
src/canopy/llm/openai.py Show resolved Hide resolved
src/canopy/llm/openai.py Show resolved Hide resolved
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Copy link
Collaborator

@igiloh-pinecone igiloh-pinecone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@igiloh-pinecone igiloh-pinecone added this pull request to the merge queue Nov 15, 2023
Merged via the queue into pinecone-io:main with commit 5897d16 Nov 15, 2023
10 checks passed
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

Successfully merging this pull request may close these issues.

None yet

2 participants