Inspiration
I wanted to build something under the Security & Online Safety theme since I hadn’t explored that domain before. The idea for ThreatSnap came while brainstorming how the GPT-4o model could be used practically in surveillance and security. I realized combining it with real-time computer vision could lead to a powerful tool — and that’s how ThreatSnap was born.
What It Does
ThreatSnap is an AI-assisted video surveillance system that analyzes CCTV/video footage for human movement. When motion is detected:
- It captures a screenshot of the scene.
- The screenshot is passed to GPT-4o, which analyzes the image for threat indicators like posture, weapons, or dangerous behavior.
- If a threat is detected, it:
- Sends an email alert with analysis.
- Triggers an external alarm system (if configured).
- Logs the detection with structured metadata.
- Updates a dashboard with analytics such as threat levels, timelines, and object profiles.
How I Built It
- Backend: Python with Flask.
- Computer Vision: YOLOv8 (
ultralytics) for detecting people and tracking movement. - AI Integration: GPT-4o for image-based threat analysis via OpenAI API.
- Email Alerts: Configurable SMTP email alerts with screenshots attached.
- Data Handling: JSON-based logs with timestamped screenshots.
- Dashboard: HTML/CSS frontend with live feed, logs, and analytics.
- Modular Architecture: Components like
detector.py,emailer.py,processor.pyare well-separated.
Challenges We Ran Into
- Learning how to use YOLOv8 effectively in a resource-optimized way.
- Ensuring screenshot quality and relevance — filtering only meaningful frames.
- Managing performance and cost while using a cloud-based LLM (GPT-4o).
- Handling screenshot analysis rate and preventing false positives via zone filtering and movement thresholds.
Accomplishments That We're Proud Of
- Built a fully working MVP with real-time movement detection, AI-driven threat assessment, and a functional web dashboard.
- Integrated an option for external system support (alarms), which shows potential for deployment in real-world CCTV setups.
What We Learned
- Gained hands-on experience with YOLOv8, threaded detection loops, and video frame handling.
- Learned to use GPT-4o multimodal capabilities for visual reasoning and structured JSON responses.
What's Next for ThreatSnap
- Run completely offline using a local LLM and YOLO models for deployment in sensitive or remote areas.
- Add real-time CCTV support instead of static videos.
- Optimize detection to only capture frames that suggest danger, reducing API calls and noise.
- Add user authentication, mobile support, and role-based access for multi-user environments.
- Create a custom hardware integration pipeline for embedded systems and smart surveillance hardware.
Log in or sign up for Devpost to join the conversation.