How rvgonzales0426/crimemapper works
Crime Mapper is a role-gated crime-analysis dashboard for police officers. The main workflow is to sign in, browse and filter incident records, inspect their map and hotspot analyses, then organize related incidents into investigations and review linked persons. Separate capabilities provide dashboard summaries, Knox analysis, patrol zones, AI assistance, and administrator-managed roles. The README documents Supabase/PostGIS-backed analysis and Edge Function integrations; unsampled modules are represented only at the subsystem level.
Main entry points: supabase.js Supabase Client · incidents.js Incident Queries & KDE · HotspotMapView.vue Hotspot Map · index.js Route & Access Guard
Components 22
Access & Shell
- Route & Access Guard
src/router/index.js - Authentication & Roles
src/stores/auth.js - Dashboard Shell
src/App.vue - User & Role Admin
src/views/AdminView.vue
Incident Analysis
- Incident Browser
src/views/IncidentsView.vue - Incident Queries & KDE
src/stores/incidents.js - Dashboard Summaries
src/views/DashboardView.vue - Hotspot Map
src/views/HotspotMapView.vue - Knox Analysis
src/stores/knox.js - Patrol Zones
src/stores/patrol.js
Casework & People
- Investigation Cases
src/stores/investigations.js - Case Detail & Assistant
src/views/InvestigationDetailView.vue - Ask AI Panel
src/components/AssistantPanel.vue - Assistant Requests
src/stores/assistant.js - Persons Index
src/stores/persons.js
Data & Integrations
- Supabase Client
src/lib/supabase.js - Supabase Database
- Case Assistant Function
supabase/functions/case-assistant/index.ts - Incident Embedding Function
supabase/functions/embed-incidents/index.ts - Groq AI Service
- Incident Data Ingest
ingest.js
Other components
- Officer
Connections 28
- Officer → Route & Access Guard: opens pages
src/router/index.js - Route & Access Guard → Authentication & Roles: checks access
src/router/index.js - Route & Access Guard → Dashboard Shell: renders routes
src/App.vue - Dashboard Shell → User & Role Admin: hosts view
src/App.vue - User & Role Admin → Authentication & Roles: reads identity
src/views/AdminView.vue - User & Role Admin → Supabase Client: manages accounts
- Incident Browser → Incident Queries & KDE: requests incidents
src/views/IncidentsView.vue - Incident Queries & KDE → Supabase Client: queries incidents
src/stores/incidents.js - Supabase Client → Supabase Database: reads and writes
src/lib/supabase.js - Dashboard Summaries → Incident Queries & KDE: uses incident data
src/views/DashboardView.vue - Hotspot Map → Incident Queries & KDE: loads map and KDE
src/views/HotspotMapView.vue - Hotspot Map → Knox Analysis: loads analysis
src/views/HotspotMapView.vue - Hotspot Map → Patrol Zones: loads zones
src/views/HotspotMapView.vue - Knox Analysis → Supabase Client: fetches Knox data
src/stores/knox.js - Patrol Zones → Supabase Client: fetches patrol data
src/stores/patrol.js - Case Detail & Assistant → Investigation Cases: loads case
src/views/InvestigationDetailView.vue - Investigation Cases → Supabase Client: stores casework
src/stores/investigations.js - Investigation Cases → Incident Queries & KDE: maps incident rows
src/stores/investigations.js - Case Detail & Assistant → Ask AI Panel: renders panel
src/views/InvestigationDetailView.vue - Ask AI Panel → Assistant Requests: submits questions
src/components/AssistantPanel.vue - Assistant Requests → Supabase Client: invokes function
src/stores/assistant.js - Assistant Requests → Case Assistant Function: requests answers
- Case Assistant Function → Groq AI Service: generates responses
- Incident Browser → Persons Index: shows linked people
src/views/IncidentsView.vue - Persons Index → Supabase Client: reads person records
src/stores/persons.js - Incident Data Ingest → Supabase Database: loads incidents
- Incident Data Ingest → Incident Embedding Function: updates embeddings
- Incident Embedding Function → Supabase Database: stores embeddings