Closed wierdvanderhaar closed 1 month ago
To use it run
pip install -U langchain-openai
...
Should already be part of the requirements.txt: https://github.com/crate/cratedb-examples/blob/f8637a0134cb7188c89521f54e97869fc1066bbf/topic/machine-learning/llm-langchain/requirements.txt#L8
Summary of the changes / Why this is an improvement
In the original code you get the following warning: LangChainDeprecationWarning: The class
langchain_community.embeddings.openai.OpenAIEmbeddings
was deprecated in langchain-community 0.1.0 and will be removed in 0.2.0. An updated version of the class exists in the langchain-openai package and should be used instead. To use it runpip install -U langchain-openai
and import asfrom langchain_openai import OpenAIEmbeddings
.Checklist