Trying To Get The Nodes From The Retrieve Function
Trying To Get The Nodes From The Retrieve Function
At a glance
The community member is trying to retrieve nodes using the VectorContextRetriever function, but is getting an empty list as the result. Another community member suggests that the issue might be with the VectorContextRetriever and that the community member might be missing the vector store. The solution provided by another community member is to add the vector_store=index.vector_store parameter to the VectorContextRetriever function, which seems to have resolved the issue.
this code (without vectorcontexretriever) works fine: # use retriever = index.as_retriever( include_text=False, # include source chunk with matching paths similarity_top_k=5, # top k for vector kg node retrieval ) nodes = retriever.retrieve("who is bob?")