Skip to content

Athul64/CrisisHub

Repository files navigation

๐Ÿšจ CrisisHub — Campus Emergency SOS

CrisisHub is a Campus Rapid Crisis & SOS Coordination Hub designed for fast emergency reporting and response in educational institutions.

Built for a "Build with AI" hackathon, this project is tailored for Adi Shankara Institute and leverages Google Gemini AI to act as an intelligent emergency dispatcher.


๐Ÿง  Overview

During emergencies, students often panic and fail to communicate clearly.
CrisisHub solves this problem by:

  • Accepting raw input (text, voice, images)
  • Using AI to classify the situation instantly
  • Providing immediate safety instructions
  • Generating a tactical brief for responders

โš™๏ธ Tech Stack

  • Framework: Next.js 16 (App Router)
  • Styling: Tailwind CSS v4 + Custom CSS (Glassmorphism, Dark Mode)
  • AI Integration: Gemini 1.5 Flash (@google/genai)
  • Icons: Lucide React
  • Deployment: Vercel-ready

๐Ÿ”„ High-Level Workflow

CrisisHub has two main interfaces:

๐Ÿ“ฑ 1. Student View (/)

Mobile-first design for high-stress situations.

๐Ÿ”ด SOS Ready State

  • Large animated SOS button
  • Clean, distraction-free UI

๐Ÿ“ Data Collection

  • Quick crisis buttons (๐Ÿ”ฅ Fire, ๐Ÿฅ Medical, ๐Ÿšจ Intruder)
  • ๐ŸŽค Voice input
  • ๐Ÿ“ท Image upload
  • ๐Ÿ“ Location selector (campus-based)

๐Ÿค– AI Analysis

  • Data sent to /api/crisis-eval

  • Gemini processes:

    • Description
    • Location
    • Image (if available)
  • Returns structured output:

    • Threat level (Low → Critical)
    • Incident type
    • Severity score
    • Required responders

๐Ÿ›‘ Fallback Mechanism

  • If AI fails → local keyword-based logic handles classification

โœ… Result Screen

  • Displays:
    • Help ETA
    • AI-generated safety steps
  • Option to share emergency report

๐Ÿ–ฅ๏ธ 2. Responder Dashboard (/dashboard)

Desktop-first command center for security teams.

๐Ÿ“ก Live Monitoring

  • Real-time alert polling
  • Visual + sound alerts for new incidents

๐Ÿ“Š Metrics

  • Total active alerts
  • Critical/High alerts
  • Affected locations summary

๐Ÿ” Alert Management

  • Filter by severity
  • Search by keywords

๐Ÿงพ AI Tactical Brief

Each alert includes:

  • Clear situation summary
  • Suggested actions
  • Required response units

๐Ÿš“ Response System

  • Responders can:

    • Accept alert
    • Add ETA
    • Send message to student
  • Alerts marked as Responded with timestamp


๐Ÿ”— Communication System

  • Uses localStorage for simulated real-time updates
  • Lightweight solution (no heavy database)
  • Ideal for hackathon/demo environments

๐ŸŽฏ Key Features

  • โšก Instant AI-powered crisis classification
  • ๐Ÿง  Multimodal input (Text, Voice, Image)
  • ๐Ÿ›Ÿ Real-time safety instructions
  • ๐Ÿ“ก Live responder dashboard
  • ๐Ÿ”„ AI fallback system
  • ๐Ÿ“ Campus-specific location mapping

๐Ÿ–ผ๏ธ Screenshots

๐Ÿ’ป IDE Preview

IDE Screenshot

๐Ÿ“ฑ Student Interface

Student View Student View Student View

๐Ÿ–ฅ๏ธ Dashboard

Dashboard Dashboard


๐Ÿš€ Getting Started

git clone https://github.com/Athul64/CrisisHub.git
cd CrisisHub
npm install
npm run dev

About

An AI-powered SOS and Crisis Coordination Hub for university campuses. Built with Next.js and the Gemini 1.5 Flash API to instantly analyze emergencies and guide students to safety. Built for GDG Build with AI @ ASIET

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors