feat: fix TKG external_id mismatch, add trace delete/merge endpoints, fix no-faces progress update

- identity_binding.rs: match both face_track_N and trace_N external_id formats in bind/unbind/create_pending_person
- profile.rs: fix external_id matching and parameter ordering in trace profile updates
- trace_agent_api.rs: add DELETE /trace/:id (soft/hard delete) and POST /trace/:src/merge/:target endpoints
- qdrant_db.rs: add delete_points_by_filter method
- tkg.rs: add debug logging for scroll and parse operations
- job_worker.rs: update progress for no-faces TKG path
This commit is contained in:
Accusys
2026-07-21 02:45:34 +08:00
parent d25b5921f7
commit 0ad6927d25
6 changed files with 368 additions and 51 deletions
+29
View File
@@ -740,6 +740,35 @@ impl QdrantDb {
Ok(())
}
pub async fn delete_points_by_filter(
&self,
collection: &str,
filter: serde_json::Value,
) -> Result<u64> {
let url = format!("{}/collections/{}/points/delete", self.base_url, collection);
let body = serde_json::json!({
"filter": filter
});
let resp = self
.client
.post(&url)
.header("api-key", &self.api_key)
.header("Content-Type", "application/json")
.json(&body)
.send()
.await
.context("Failed to delete points from Qdrant")?;
if !resp.status().is_success() {
anyhow::bail!("Qdrant delete failed: {}", resp.status());
}
// Qdrant returns {"result": {"operation_id": N, "status": "completed"}}
Ok(1) // Qdrant doesn't return count, just return 1 to indicate success
}
pub async fn get_point_count(&self) -> Result<usize> {
let url = format!(
"{}/collections/{}/info",