Add Neptune-DB graph store with vector store#3443
Add Neptune-DB graph store with vector store#3443parshvadaftari merged 18 commits intomem0ai:mainfrom
Conversation
|
@acarbonetto the tests are failing and also please update the corresponing the documentation. The corresponding changes to documentation is required since this PR will introduce 2 different providers for Graphstore. |
|
|
||
| - For more details on how to connect, configure, and use the graph_memory graph store, see the [Neptune Analytics example notebook](examples/graph-db-demo/neptune-analytics-example.ipynb). | ||
|
|
||
| ### Initialize Neptune DB |
There was a problem hiding this comment.
Can you match the writing style with kuzu , neo4j and other graph store. This focuses on the neptunedb and some of the additional things seem irrelevant.
There was a problem hiding this comment.
I thought the details on the instance setup were necessary. A user would need to setup an instance for testing or the first time.
I will move the instance setup details under the usage header then, to match the documentation style. But I would prefer to keep these details - at least that's my perspective.
There was a problem hiding this comment.
Please take a look at b8f45cc. I've made documentation updates and remove sub-headers, as well as simplified the documentation. Let me know if you have any further suggestions.
| results.append(result) | ||
| return results | ||
|
|
||
| @abstractmethod |
There was a problem hiding this comment.
why is this removed?
There was a problem hiding this comment.
This abstractmethod was doing too much in the base and is no longer being extended. Now, instead this method is implemented here and calls either:
- _add_entities_by_source_cypher
- _add_entities_by_destination_cypher
- _add_relationship_entities_cypher
- _add_new_entities_cypher
these 4 methods are @abstractmethods and extended in both the neptunedb.py and neptunegraph.py files.
b445559 to
b8f45cc
Compare
|
@acarbonetto Can you resolve merge conflicts? |
b8f45cc to
1fad15c
Compare
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
…on name in config Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com>
2791ee3 to
fa32636
Compare
parshvadaftari
left a comment
There was a problem hiding this comment.
Looks good to me.
|
@acarbonetto Thanks a lot for contributing |
Signed-off-by: Andrew Carbonetto <andrew.carbonetto@improving.com> Co-authored-by: Siddhartha Sahu <dev@sdht.in>
Description
This feature adds a graph_store option to connect to Amazon Neptune clusters (Neptune DB). Neptune DB is more permanent storage than Neptune Analytics, which may be preferable in certain cases. However, Neptune DB lacks vector storage - and for this reason, when configured in mem0, the graph_store will store edge vectors in the vector_store.
Amazon Neptune DB can be configured, for example:
note: That
collection_nameis available for both the vector and graph stores.Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Please delete options that are not relevant.
tests/memory/test_neptune_memory.pyexamples/graph-db-demo/neptune-example.ipynbChecklist:
Maintainer Checklist