Skip to content

Bumps langchain version, fixes upsert type error - #71

Open
prosocres wants to merge 11 commits into
a16z-infra:mainfrom
prosocres:main
Open

Bumps langchain version, fixes upsert type error#71
prosocres wants to merge 11 commits into
a16z-infra:mainfrom
prosocres:main

Conversation

@prosocres

Copy link
Copy Markdown

I recently forked the repo, followed the Quickstart guide and received an error on step 4 ("Generate embeddings"):

PineconeArgumentError: The argument to upsert had type errors: argument must be array.

Did a little digging and think it may have been caused by the Pinecone and Langchain upgrade cycles:

  • When the package.json file was bumped on Jun 7, the Pinecone major version was bumped from '0' to '2' (see commit log)
  • As part of Pinecone's major version 1 release they made changes to upsert (see migration guide)
  • Later versions of Langchain appear to be compatible with this change, but some of the interim versions (for example, 0.0.214) had dev dependency conflicts with Pinecone 2.2.2
  • So even though the package.json file has minor version support via the semver notation - "langchain": "^0.0.100", - the package-lock.json file suggested it was still only using langchain version 0.0.100

Solution: Bumping the package.json dependency to "langchain": "^0.1.37" resolved the type error and allowed me to run the app in dev mode.

Not sure if anyone else had this issue or is able to replicate it but thought I would share what worked for me.

@prosocres

Copy link
Copy Markdown
Author

@ykhli and @timqian - I'm not sure I have permission to add reviewers so thought I would direct this to you since you are listed in the "Code contribution workflow" section of the README.md file.

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.

1 participant