fix: 使用正确的 face_cluster API 端点

- 改用 POST /api/v1/file/:uuid/json/face_cluster
- 替换旧的 GET /api/v1/cluster-results
- 返回正确的 cluster 数据:status, clusters, frames
- 修复 face dedup 按钮无法工作的问题
- 添加 get_file_processor_json API (通用端点)
This commit is contained in:
2026-10-01 11:10:44 +08:00
parent f3d75ebce8
commit fef3b892d6

View File

@@ -543,7 +543,7 @@ case 'search_keyword': {
return { url: `/api/v1/file/${a.fileUuid}/cluster-agent`, method: 'POST', body: { confirm: true }, timeout: 600000 }
}
case 'get_cluster_results': {
return { url: `/api/v1/cluster-results?file_hash=${a.fileHash}&include_trace_ids=false`, method: 'GET' }
return { url: `/api/v1/file/${a.fileHash}/json/face_cluster`, method: 'POST', body: {} }
}
case 'get_similar_face_groups': {
const params = new URLSearchParams()
@@ -566,6 +566,9 @@ case 'search_keyword': {
case 'get_processor_json': {
return { url: `/api/v1/processor-json?file_hash=${a.fileHash}&processor=${a.processor}`, method: 'GET' }
}
case 'get_file_processor_json': {
return { url: `/api/v1/file/${a.fileUuid}/json/${a.processor}`, method: 'POST', body: {} }
}
case 'create_pending_identity': {
return { url: '/api/v1/identities/pending', method: 'POST', body: { file_uuid: a.fileUuid, trace_id: a.traceId, face_id: a.faceId, cluster_id: a.clusterId, trace_count: a.traceCount } }
}