Duplicate Activity Detector
Component Detail
Infrastructure
high complexity
backend
2
Dependencies
0
Dependents
1
Entities
0
Integrations
Description
Supabase database trigger or scheduled Edge Function that compares activity fingerprints (date, type, participant overlap) within a configurable time window across different coordinator registrations at different hierarchy levels. Flags suspected duplicates for review rather than auto-deleting, satisfying the NHF requirement.
duplicate-activity-detector
Responsibilities
- Compare activity fingerprints across coordinator submissions
- Detect same event registered by multiple coordinators at different levels
- Flag duplicates and notify relevant coordinators
- Support configurable time-window and similarity thresholds
Interfaces
checkForDuplicates(activityId)
computeFingerprint(activity)
flagDuplicate(activityId, duplicateOfId)
getDuplicateFlagsForUnit(unitId)
resolveDuplicate(flagId, resolution)
Relationships
Dependencies (2)
Components this component depends on