SafeShift
Your security cameras, now spotting hazards.
Guided demo
This replays real screens from SafeShift, with the timing sped up. It is not the live app.
-
Cameras you already have. Your existing security cameras become hazard detectors. -
A spill, spotted. Gemini flags a liquid spill at 95% confidence. -
One frame isn't enough. A single frame never alerts. The hazard has to appear in 3 of 5. -
Rules, not guesses. A hand-written table, not the model, sets the severity to HIGH and names the Floor Lead to review. -
Straight to the queue. The alert arrives with the exact frame that triggered it. -
A person makes the call. Confirm, False alarm, Assign or Resolve. No video is stored, only this frame. -
What cameras can't see. Workers can photograph a hazard from their phone. -
The hard message, drafted. Gemini writes a polite note to the manager. The worker can edit it or report anonymously. -
Safe to speak up. “You won't get in trouble for reporting.” The report joins the same queue.
How it works
- 01 CanvasCapture
A frame is pulled from the camera video about every 2 seconds and downscaled to roughly 768px.
Browser - 02 Gemini 2.5 FlashLook
Answers in a fixed JSON schema: hazard type, confidence and evidence. It looks at the environment, not at people.
Server route - 03 Temporal gateConfirm
Keeps the last 5 frames and needs the same hazard in 3 of them. A single frame never alerts.
Browser - 04 Rules tableDecide
A hand-written table sets the severity, the action and the reviewer. It overrides the model's guess.
Browser - 05 Human reviewReview
The alert and the one frame that triggered it are saved, and the dashboard updates in realtime. A person confirms, dismisses, assigns or resolves it.
Firestore - Side path Worker appWorker photo
For spots no camera covers, a worker photographs the hazard. Gemini drafts a summary and a polite note on its own server route, the same rules set the severity, and the report lands in the same queue. It skips the temporal gate.
Phone + server route
The hazard types are liquid spill, blocked exit, blocked extinguisher, blocked accessible path, walkway obstruction, trip hazard cable, or none. Only the Gemini call runs on the server, which keeps the API key off the client. The gate needs a rolling window of recent frames, so it runs in the browser with the rules and the Firestore write.
Background
A lot of workplace accidents start as a near-miss nobody writes down: a spill during a rush, boxes in front of an exit, a blocked fire extinguisher. SafeShift tries to catch those early, with human review on every alert.
We built it in 24 hours at QuackHacks 3.0 at the University of Oregon, in spring 2026. It was a team of three. I did the architecture, AI and backend: the Gemini schema, the temporal gate, the rules layer and the integration. Bawan built the monitoring frontend and design, and Haddy built the manager workflow and the worker side.
It is a hackathon project, kept as built. There is no live instance, which is why the demo above replays real screens.
Tech
- Next.js 16
- React 19
- TypeScript
- Tailwind CSS v4
- Gemini 2.5 Flash
- Cloud Firestore
- Firebase Storage
- Firebase App Hosting