def _delete(self, doc_id: str, **delete_kwargs: Any) -> None:
"""Delete a document."""
self._index_struct.delete(doc_id)
self._vector_store.delete(doc_id)
def delete(self, doc_id: str) -> None:
"""Delete a Node."""
if doc_id not in self.doc_id_dict:
raise ValueError("doc_id not found in doc_id_dict")
for vector_id in self.doc_id_dict[doc_id]:
del self.nodes_dict[vector_id]
del self.doc_id_dict[doc_id
return GPTQdrantIndex(
nodes=[],
client=qdrant_client_instance,
service_context=service_context,
collection_name=self._collection_name,
)