1use serde::Serialize;
2
3#[derive(Serialize, Clone)]
6pub struct PersonData {
7 pub label: String,
9 pub full_name: String,
12 pub face_ids: Vec<i64>,
13 pub representative_id: i64,
14 pub hashes: Vec<String>,
15}
16
17#[derive(Serialize, Clone)]
19pub struct ClusterData {
20 pub cluster_id: i64,
21 pub face_ids: Vec<i64>,
22 pub hashes: Vec<String>,
23}
24
25#[derive(Serialize, Clone)]
27pub struct SingletonData {
28 pub face_id: i64,
29 pub hash: String,
30}
31
32#[derive(Serialize, Clone, Default)]
37pub struct FacesData {
38 pub people: Vec<PersonData>,
39 pub clusters: Vec<ClusterData>,
40 pub singletons: Vec<SingletonData>,
41}
42
43#[derive(Serialize, Clone)]
45pub struct ClusterFaceData {
46 pub face_id: i64,
47 pub hash: String,
48 pub path: String,
49}
50
51#[derive(Serialize, Clone)]
53pub struct ClusterDetail {
54 pub cluster_id: i64,
55 pub faces: Vec<ClusterFaceData>,
56}
57
58#[derive(Serialize, Clone)]
61pub struct PersonFaceData {
62 pub face_id: i64,
63 pub hash: String,
64 pub path: String,
65 pub is_primary: bool,
66}
67
68#[derive(Serialize, Clone)]
70pub struct PersonDetail {
71 pub label: String,
73 pub full_name: String,
75 pub faces: Vec<PersonFaceData>,
76}