LockIn is a privacy-first, AI-powered focus tracking application designed to help students maintain concentration while studying. It uses real-time computer vision running entirely in your browser to detect focus, distractions, phone usage, and absence.
- 🎯 Real-time Focus Detection: Uses AI to track your gaze and head pose
- 📱 Phone Detection: Alerts when you pick up your phone
- 🚶 Absence Detection: Tracks when you leave your desk
- ⚡ Quick Nudge: Gentle 3-second warning before the main alert
- 📊 Session Timeline: Visual history of your entire study session
- 📈 Detailed Stats: Focus time, distractions, phone time, and absent time
- 🔒 100% Private: All processing happens on your device - no data leaves your browser
- 📱 PWA Support: Install as a standalone app and use offline
# Install dependencies
npm install
# Run development server
npm run dev
# Build for production
npm run build- Vite - Fast build tool
- TensorFlow.js - Machine learning in the browser
- MediaPipe Face Mesh - High-fidelity face landmark detection
- COCO-SSD - Object detection for phone identification
- PWA - Progressive Web App capabilities
- Face Detection: Uses MediaPipe to detect 468 facial landmarks
- Gaze Analysis: Calculates head pose to determine if you're looking at the screen
- Phone Detection: COCO-SSD model identifies cell phones in the frame
- State Tracking: Monitors your state (Focused, Distracted, Phone, Absent)
- Visual Feedback: Color-coded ambient glow and timeline visualization
- 🟢 Green - Focused
- 🔴 Red - Distracted
- 🟡 Yellow - Phone detected
- ⚪ Grey - Absent
- Face Mesh: Toggle the wireframe overlay
- Timeline Duration: Choose view range (1h, 2h, 4h, 8h, 24h)
All video processing happens locally in your browser. No video data is ever sent to any server. Your study sessions remain completely private.
MIT