langchain/libs/community/langchain_community/graph_vectorstores
Eric Pinzur f636c83321
community: Cassandra Vector Store: modernize implementation (#27253)
**Description:** 

This PR updates `CassandraGraphVectorStore` to be based off
`CassandraVectorStore`, instead of using a custom CQL implementation.
This allows users using a `CassandraVectorStore` to upgrade to a
`GraphVectorStore` without having to change their database schema or
re-embed documents.

This PR also updates the documentation of the `GraphVectorStore` base
class and contains native async implementations for the standard graph
methods: `traversal_search` and `mmr_traversal_search` in
`CassandraVectorStore`.

**Issue:** No issue number.

**Dependencies:** https://github.com/langchain-ai/langchain/pull/27078
(already-merged)

**Lint and test**: 
- Lint and tests all pass, including existing
`CassandraGraphVectorStore` tests.
- Also added numerous additional tests based of the tests in
`langchain-astradb` which cover many more scenarios than the existing
tests for `Cassandra` and `CassandraGraphVectorStore`

** BREAKING CHANGE**

Note that this is a breaking change for existing users of
`CassandraGraphVectorStore`. They will need to wipe their database table
and restart.

However:
- The interfaces have not changed. Just the underlying storage
mechanism.
- Any one using `langchain_community.vectorstores.Cassandra` can instead
use `langchain_community.graph_vectorstores.CassandraGraphVectorStore`
and they will gain Graph capabilities without having to re-embed their
existing documents. This is the primary goal of this PR.

---------

Co-authored-by: Erick Friis <erick@langchain.dev>
2024-10-22 18:11:11 +00:00
..
extractors multiple: update docs urls to latest 2 (#26837) 2024-09-30 17:37:07 -07:00
__init__.py community: Cassandra Vector Store: modernize implementation (#27253) 2024-10-22 18:11:11 +00:00
base.py community: Cassandra Vector Store: modernize implementation (#27253) 2024-10-22 18:11:11 +00:00
cassandra.py community: Cassandra Vector Store: modernize implementation (#27253) 2024-10-22 18:11:11 +00:00
links.py community[patch]: Add docstring for Links (#25969) 2024-09-30 20:33:50 +00:00
mmr_helper.py community: Cassandra Vector Store: modernize implementation (#27253) 2024-10-22 18:11:11 +00:00
networkx.py community: Add conversions from GVS to networkx (#26906) 2024-09-27 16:48:55 -04:00