I've got an existing neo4j graph with some nodes and relationships between them.
The nodes "Chunks" have the following properties:
- text: wich contains a text chunk
- embedding: which contains a vector representation (1536) dimension of text
Now I want to attach LlamaIndex with this existing graph and the existing index build with neo4j.
So i can do the following:
neo4j_vector = Neo4jVectorStore(
embedding_dimension=1536,
username=os.getenv("NEO4J_USERNAME"),
password=os.getenv("NEO4J_PASSWORD"),
url=os.getenv("NEO4J_URL"),
index_name=VECTOR_INDEX_NAME,
text_node_property=VECTOR_SOURCE_PROPERTY,
embedding_node_property='embedding',
node_label=VECTOR_NODE_LABEL,
)
retriever = VectorStoreIndex.from_vector_store(neo4j_vector).as_retriever()
retriever.retrieve("my query").
But I've got the following error:
ValueError("Node content not found in metadata dict.")
I think that llama is expecting a metadata dictionary in the nodes (because i didn't creare the embeddings and the nodes with llama).
How can i resolve this?