Smart Fridge monitors your fridge, alerts you when food is about to expire, or when someone steals your food. In addition, it can generate recipe based on items in fridge with the help of OpenAI API.
- Temperature & Humidity Tracking — Continuous sensor data from the Raspberry Pi, displayed live on the dashboard
- Door Status Detection — Know when the fridge is opened or closed in real time
- On-Device Object Detection — YOLO-v5 running on Raspberry Pi identifies food items inside the fridge
- Automatic Inventory Sync — Detected items are synced to the backend and reflected on the web UI instantly
- Smart Item Lifecycle — Items that disappear for multiple scans are automatically removed from inventory
- Custom Expiration Dates — Set or update expiration dates for any item via the calendar picker
- Proactive Expiry Alerts — Get notified when items are within 3 days of expiring so nothing goes to waste
- Face Verification — Verify authorized users via the web camera or Raspberry Pi camera module
- Unauthorized Access Detection — Items removed by unverified users are flagged as "stolen" and displayed with a badge
- Time-Bound Verification — Verified faces are stored for 3 minutes, covering typical fridge access windows
- Smart Recipe Suggestions — Powered by OpenAI ChatGPT, generates recipe ideas based on the actual items currently in your fridge
- One-Click Access — Tap "Generate Recipe" on the dashboard for instant meal inspiration
- Live Fridge State — Real-time temperature, humidity, and door status at a glance
- Visual Item Cards — Each item shows name, date added, expiration date, and theft status
- Push Notifications — Toast notifications for expiry warnings and system events
- Responsive Design — Mobile-first UI built with React, Tailwind CSS, and shadcn/ui
- Raspberry Pi 4B x3
- Sensors
- Temperature and Humidity Sensor
- Camera Module (Webcam)
Frontend codebase developed using Next.js.
Python FastAPI
- Provides API endpoints for frontend and other Raspberry Pi
- Uses Redis DB to store fridge state and items in fridge
Raspberry Pi on-device detection using YOLO-v5
The system supports two modes of face verification:
Users can verify themselves through the web interface:
- Click the "Verify Face" button on the dashboard
- A camera dialog opens requesting camera access
- Capture a photo of your face
- Click "Verify" to send the image to the backend
- The backend stores your verified face in Redis for 3 minutes
- During this window, items removed from the fridge won't be marked as "stolen"
A Raspberry Pi with a camera module can perform continuous face detection:
- Captures images when the fridge door opens
- Sends face data to the backend via
POST /sync/face_detection - Verified users are stored in Redis with a 3-minute TTL
POST /sync/face_detection
Body: { "face": "<base64-encoded-image-data>" }
Stores the verified face in Redis for 180 seconds. Any food items removed during this window are not flagged as stolen.


