fix annotation failed when embedding model and dimension changed (#17347)
This commit is contained in:
@@ -46,7 +46,7 @@ def disable_annotation_reply_task(job_id: str, app_id: str, tenant_id: str):
|
||||
try:
|
||||
if annotations_count > 0:
|
||||
vector = Vector(dataset, attributes=["doc_id", "annotation_id", "app_id"])
|
||||
vector.delete_by_metadata_field("app_id", app_id)
|
||||
vector.delete()
|
||||
except Exception:
|
||||
logging.exception("Delete annotation index failed when annotation deleted.")
|
||||
redis_client.setex(disable_app_annotation_job_key, 600, "completed")
|
||||
|
Reference in New Issue
Block a user