refactor: rename dataset db handler to pgvector as it works in the cloud too
This commit is contained in:
parent
0903092fc9
commit
ff3435657b
3 changed files with 9 additions and 3 deletions
2
.github/workflows/vector_db_tests.yml
vendored
2
.github/workflows/vector_db_tests.yml
vendored
|
|
@ -149,7 +149,7 @@ jobs:
|
|||
VECTOR_DB_PORT: 5432
|
||||
VECTOR_DB_USERNAME: cognee
|
||||
VECTOR_DB_PASSWORD: ${{ secrets.POSTGRES_PASSWORD }}
|
||||
VECTOR_DATASET_DATABASE_HANDLER: pgvector_local
|
||||
VECTOR_DATASET_DATABASE_HANDLER: pgvector
|
||||
run: uv run python ./cognee/tests/test_permissions.py
|
||||
|
||||
run-lancedb-tests:
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ supported_dataset_database_handlers = {
|
|||
"handler_provider": "neo4j",
|
||||
},
|
||||
"lancedb": {"handler_instance": LanceDBDatasetDatabaseHandler, "handler_provider": "lancedb"},
|
||||
"pgvector_local": {
|
||||
"pgvector": {
|
||||
"handler_instance": PGVectorDatasetDatabaseHandler,
|
||||
"handler_provider": "pgvector",
|
||||
},
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ class PGVectorDatasetDatabaseHandler(DatasetDatabaseHandlerInterface):
|
|||
"password": vector_config.vector_db_password,
|
||||
"host": vector_config.vector_db_host,
|
||||
},
|
||||
"vector_dataset_database_handler": "pgvector_local",
|
||||
"vector_dataset_database_handler": "pgvector",
|
||||
}
|
||||
|
||||
from .create_db_and_tables import create_pg_database
|
||||
|
|
@ -59,6 +59,12 @@ class PGVectorDatasetDatabaseHandler(DatasetDatabaseHandlerInterface):
|
|||
|
||||
return new_vector_config
|
||||
|
||||
@classmethod
|
||||
async def resolve_dataset_connection_info(
|
||||
cls, dataset_database: DatasetDatabase
|
||||
) -> DatasetDatabase:
|
||||
return dataset_database
|
||||
|
||||
@classmethod
|
||||
async def delete_dataset(cls, dataset_database: DatasetDatabase):
|
||||
vector_engine = create_vector_engine(
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue