-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
DOC: RAG Search example validation error #17039
Comments
🤖 Based on the error message you provided, it seems like the The The Here's a possible workaround: you can manually create the from langchain_community.vectorstores import DocArrayInMemorySearch, DocArrayDoc
from langchain_openai.embeddings import OpenAIEmbeddings
texts = ["harrison worked at kensho", "bears like to eat honey"]
embedding = OpenAIEmbeddings()
docs = [DocArrayDoc(text=text, metadata={}, embedding=embedding.embed(text)) for text in texts]
vectorstore = DocArrayInMemorySearch(docs) In this code, we're creating a list of Please note that this is a workaround and might not be the best solution. The issue might be due to a bug in the I hope this helps! If you have any other questions, feel free to ask. For more information about the -Dosu Sources
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research. Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant. If you want to continue the conversation, start your reply with @dosu-bot. |
I tried the exact same code and everything is working fine at my end. Can you please upgrade your |
Strange, it doesn't work for me. My versions: langchain 0.1.5 Full error:
|
I found that this happens once I install langflow. I started a fresh environment and it works. |
Issue with current documentation:
I am going through the examples in the documentation in a Jupyter Lab notebook. I'm running the code from here:
I'm getting this error message on the chain.invoke():
Is the code in the docs obsolete or is this a problem of my setup? I'm using langchain 0.1.5 and Python 3.11.
Idea or request for content:
No response
The text was updated successfully, but these errors were encountered: