Forensic Identification System
Reuniting families through technology
A comprehensive platform for reporting, searching, and matching missing persons with unidentified bodies using AI-powered facial recognition and vector search.
FORENSYNC is an advanced forensic identification system that leverages AI and machine learning to help law enforcement agencies, forensic departments, and families identify missing persons and unidentified bodies. The platform combines traditional database management with cutting-edge facial recognition and semantic search capabilities.
- π AI-Powered Search - Text-based and image-based search with semantic matching
- π€ Facial Recognition - InsightFace-powered facial embeddings for accurate matching
- ποΈ Vector Database - Qdrant for high-performance similarity search
- π Real-time Dashboard - Live statistics and case management
- πΈ Multi-Photo Support - Profile and additional evidence photos
- π Geolocation - GPS coordinates for last seen/found locations
- π Unique IDs - Auto-generated PIDs (MP-2024-XXXXX, UIDB-2024-XXXXX)
Backend
- FastAPI - High-performance Python API framework
- SQLite - Lightweight relational database
- Qdrant - Vector similarity search engine
- InsightFace - State-of-the-art facial recognition
- Sentence Transformers - Text embedding models
Frontend
- React 18 - Modern UI library
- Vite - Lightning-fast development server
- React Router - Client-side routing
- Tailwind CSS 3 - Utility-first styling
- Axios - HTTP client
Design System
- Matter Font - Warp.dev's professional typeface
- Dark Theme - #0D0D0D background with #F87171 coral accents
- Animations - Smooth transitions and micro-interactions
FORENSYNC/
βββ backend/
β βββ main.py # FastAPI application
β βββ db_helper.py # Database operations
β βββ face_embedding.py # Facial recognition
β βββ text_embedder.py # Text embedding
β βββ vector_retrieval.py # Vector search
β βββ vectordb.py # Qdrant integration
β βββ missing_persons.db # SQLite database
β βββ qdrant_data/ # Vector storage
β βββ photos/ # Image storage
β
βββ frontend/
β βββ src/
β β βββ App.jsx # Router configuration
β β βββ api.js # Backend API client
β β βββ components/
β β β βββ Layout.jsx # Main layout with navbar
β β βββ pages/
β β β βββ Home.jsx # Dashboard
β β β βββ SearchMatch.jsx # Search interface
β β β βββ Records.jsx # Browse records
β β β βββ ReportMissingPerson.jsx # Report form
β β β βββ ReportUnidentifiedBody.jsx
β β βββ index.css # Global styles + animations
β β βββ main.jsx # React entry point
β βββ tailwind.config.js # Theme configuration
β βββ vite.config.js # Dev server + proxy
β βββ package.json # Dependencies
β
βββ docs/
βββ API_DOCUMENTATION.md
βββ DATABASE_README.md
βββ FACE_RECOGNITION_README.md
βββ QDRANT_SETUP.md
- Python 3.9+
- Node.js 18+
- 8GB RAM (for face recognition models)
# Install Python dependencies
pip install -r requirements.txt
pip install -r requirements_face_recognition.txt
# Initialize database
python setup_database.py
# Start FastAPI server
uvicorn main:app --reload --host 0.0.0.0 --port 8000The API will be available at http://localhost:8000
Interactive docs: http://localhost:8000/docs
# Navigate to frontend
cd frontend
# Install dependencies
npm install
# Start development server
npm run devThe app will be available at http://localhost:5173
GET /health- System health checkGET /api/stats- Dashboard statistics
POST /api/search/match- Text-based semantic searchPOST /api/search/image- Facial recognition search
GET /api/missing-persons- List all missing personsGET /api/unidentified-bodies- List all unidentified bodies
POST /api/report/missing-person- Report a missing personPOST /api/report/unidentified-body- Report an unidentified body
See API_DOCUMENTATION.md for detailed API specs.
Text Search
- Semantic matching using Sentence Transformers
- Search by name, description, physical features, clothing
- Returns ranked results with similarity scores
Image Search
- Upload a photo for facial recognition
- InsightFace embeddings with ArcFace model
- Matches against 512-dimensional face vectors
Missing Persons
- FIR number and police station
- Reporter contact information
- Physical description (height, age, gender, complexion)
- Clothing and distinguishing marks
- Last seen location with GPS coordinates
- Multiple photos support
Unidentified Bodies
- Forensic case number
- Body discovery details
- Postmortem observations
- DNA, dental, and fingerprint records
- Found location with GPS
- Evidence photos
- Total missing persons count
- Total unidentified bodies count
- Recent reports
- Match statistics
FORENSYNC follows Warp.dev's design language:
Color Palette
Background: #0D0D0D
Cards: #262626
Borders: #333333
Text Primary: #FFFFFF
Text Muted: #9B9B9B
Accent: #F87171 (Coral)Typography
- Font Family: Matter (Warp.dev's custom font)
- Weights: Regular (400), Medium (500)
Animations
- Fade-in transitions on page load
- Slide-in effects for cards
- Hover lift animations
- Shimmer loading states
| Field | Type | Description |
|---|---|---|
| pid | TEXT PRIMARY KEY | MP-2024-XXXXX |
| name | TEXT | Full name |
| age | INTEGER | Age in years |
| gender | TEXT | Male/Female/Other |
| height_cm | INTEGER | Height in cm |
| person_description | TEXT | Physical description |
| last_seen_address | TEXT | Last known location |
| last_seen_lat/lng | REAL | GPS coordinates |
| status | TEXT | Open/Matched/Closed |
| Field | Type | Description |
|---|---|---|
| pid | TEXT PRIMARY KEY | UIDB-2024-XXXXX |
| age_range | TEXT | Estimated age range |
| gender | TEXT | Gender identification |
| height_cm | INTEGER | Height in cm |
| body_description | TEXT | Physical description |
| found_address | TEXT | Discovery location |
| found_lat/lng | REAL | GPS coordinates |
| status | TEXT | Open/Matched/Closed |
See DATABASE_README.md for complete schema.
- Model: InsightFace (Buffalo_L)
- Embedding Size: 512 dimensions
- Accuracy: 99.8% on LFW benchmark
- Backend: ONNX Runtime
- Model: all-MiniLM-L6-v2
- Embedding Size: 384 dimensions
- Use Case: Semantic search across descriptions
- Engine: Qdrant
- Distance Metric: Cosine similarity
- Collections: missing_persons, unidentified_bodies
- Indexing: HNSW algorithm
- API_DOCUMENTATION.md - Complete API reference
- DATABASE_README.md - Database schema and operations
- FACE_RECOGNITION_README.md - Face recognition setup
- QDRANT_SETUP.md - Vector database configuration
- GETTING_STARTED.md - Step-by-step setup guide
Create a .env file in the root directory:
# Database
DATABASE_URL=sqlite:///./missing_persons.db
# Qdrant
QDRANT_HOST=localhost
QDRANT_PORT=6333
# Face Recognition
FACE_MODEL_PATH=./models/buffalo_l
# API
API_HOST=0.0.0.0
API_PORT=8000Edit frontend/vite.config.js to change backend URL:
export default defineConfig({
server: {
proxy: {
'/api': 'http://localhost:8000'
}
}
})python test_db_connection.py
python test_qdrant_init.py
python test_vector_retrieval.py# Run test suite
python test_api.py
# Or use the interactive docs
# Visit http://localhost:8000/docs- β CORS configured for specific origins
- β File upload validation
- β SQL injection prevention via parameterized queries
- β Photos stored with UUID filenames
- β Environment variables for sensitive data
β οΈ Production: Use HTTPS, authentication, rate limiting
# Build production
pip install -r requirements.txt
# Run with Gunicorn
gunicorn main:app --workers 4 --worker-class uvicorn.workers.UvicornWorkercd frontend
npm run build
# Deploy the 'dist' folder to a static hostThis project is part of the Hack4Safety initiative to leverage technology for social good.
MIT License - See LICENSE file for details
RaptureTwelve - Hack4Safety 2024
For issues and questions:
- π§ Check existing documentation in
/docs - π Report bugs via GitHub Issues
- π¬ Contact the development team
FORENSYNC - Bringing closure through technology
Made with β€οΈ for Hack4Safety