File size: 2,150 Bytes
1c0c94d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | // Central interpretability copy β the difference between "raw" and "readable".
export const TYPE = {
HELMET_NON_COMPLIANCE: { label: 'No Helmet', icon: 'πͺ' },
TRIPLE_RIDING: { label: 'Triple Riding', icon: 'π₯' },
SEATBELT_NON_COMPLIANCE: { label: 'No Seatbelt', icon: 'π' },
STOP_LINE_VIOLATION: { label: 'Stop-line Crossing', icon: 'π' },
RED_LIGHT_VIOLATION: { label: 'Red-light Violation', icon: 'π¦' },
ILLEGAL_PARKING: { label: 'Illegal Parking', icon: 'π
ΏοΈ' },
WRONG_SIDE_DRIVING: { label: 'Wrong-side Driving', icon: 'βοΈ' },
}
export const ROUTE = {
auto_confirmed: {
label: 'Confirmed', variant: 'ok', note: 'auto',
action: 'Auto-confirmed e-challan',
},
vlm_confirmed: {
label: 'Confirmed', variant: 'ok', note: 'AI-verified',
action: 'Confirmed after AI verification',
},
human_review: {
label: 'Needs review', variant: 'warn', note: '',
action: 'Routed to a human reviewer',
},
abstain: {
label: 'No determination', variant: 'mute', note: '',
action: 'Abstained β evidence insufficient',
},
}
// What each evidence-sufficiency tier means, in plain English.
export const TIER_INFO = {
A: 'Appearance β provable from the photo alone (e.g. helmet, triple riding). May auto-confirm.',
B: 'Hard appearance β e.g. seatbelt; unreliable from a traffic cam, so always verified before issuing.',
C: 'Spatial β needs per-camera calibration (stop-line, red-light, parking). Never auto-confirmed.',
D: 'Temporal β needs video to prove (wrong-side driving). A single frame abstains by design.',
}
export const SUFFICIENCY_INFO = {
sufficient: 'The evidence is strong enough to stand on its own.',
candidate: 'A credible candidate that still needs confirmation.',
insufficient: 'Not enough evidence in this photo to decide β the system abstained.',
}
export const typeInfo = (t) => TYPE[t] || { label: t, icon: 'β οΈ' }
export const routeInfo = (r) => ROUTE[r] || { label: r, variant: 'mute', note: '', action: r }
// Chart palette
export const PALETTE = ['#2563eb', '#16a34a', '#d97706', '#64748b', '#9333ea', '#dc2626', '#0891b2']
|