neo4j / neo4j-graphrag-python

Neo4j GraphRAG for Python
https://neo4j.com/docs/neo4j-graphrag-python/current/
Other
231 stars 37 forks source link

Database not used when writing in Ne04jWriter #214

Open asmita-mukherjee opened 10 hours ago

asmita-mukherjee commented 10 hours ago

Code Link : https://github.com/neo4j/neo4j-graphrag-python/blob/8285d56e53af36d3a0a5dadd094e0982a128e6fd/src/neo4j_graphrag/experimental/components/kg_writer.py#L160

The database initialized should also be the database where the graph is written, however it currently uses the default database.

stellasia commented 6 hours ago

Hi @asmita-mukherjee ,

Thank you for the report, you're right, this is a bug, we're working on it.

In the meantime, maybe you can specify the database when you initialize the driver:

import neo4j
driver = neo4j.GraphDatabase.driver(URI, auth=AUTH, database=DATABASE)

in which case, you do not have to specify it in the writer.

asmita-mukherjee commented 5 hours ago

sure thanks :)