Bugfix langchain astradb metadata (#4361)

* bugfix: langchain-astradb expects None or Iterable

* Update astradb.py
This commit is contained in:
Eric Hare
2024-11-01 15:39:48 -07:00
committed by GitHub
parent 85cffda753
commit e6486896fc

View File

@ -420,8 +420,8 @@ class AstraVectorStoreComponent(LCVectorStoreComponent):
bulk_delete_concurrency=self.bulk_delete_concurrency or None,
setup_mode=setup_mode_value,
pre_delete_collection=self.pre_delete_collection,
metadata_indexing_include=[s for s in self.metadata_indexing_include if s],
metadata_indexing_exclude=[s for s in self.metadata_indexing_exclude if s],
metadata_indexing_include=[s for s in self.metadata_indexing_include if s] or None,
metadata_indexing_exclude=[s for s in self.metadata_indexing_exclude if s] or None,
collection_indexing_policy=orjson.dumps(self.collection_indexing_policy)
if self.collection_indexing_policy
else None,