Error in Pinecone.from_texts

from langchain.vectorstores import Pinecone as PineconeVectorStore
from pinecone import Pinecone, PodSpec

pc = Pinecone(api_key=PINECONE_API_KEY)
index = pc.Index("medcure")
docsearch = PineconeVectorStore.from_texts([t.page_content for t in data_chunks],embeddings , index_name="medcure")

please need assistance in it

2 Likes

same error and I didn`t have the answer if you got it, please response.

Hi @jonasblues86, thanks for your post. You’re running into that error because you are using an outdated version of LangChain. You can find more information in our support documentation.
Please note you will also need to update your code for the new version.