Inspiration
Personal safety is a major concern, especially when walking alone or in unfamiliar areas. I wanted to create a smart assistant that could detect potential threats in real time and take action automatically, even before the user consciously realizes the danger.
What it does
Safety-Companion continuously monitors the user’s surroundings via audio input, analyzes speech, emotion, and contextual cues, and determines the risk level in real time. It can then automatically activate safety tools such as location tracking, fake calls, alarms, or notifications to trusted contacts when a threat is detected.
How we built it
Audio capture → converts environmental sounds and speech to text. Emotion detection → detects stress, fear, or surprise in user speech. Keyword detection → identifies potential danger words (e.g., "knife", "followed"). Risk scoring → computes a numeric risk score based on stress, emotion, and context. LLM-based reasoning → considers conversation history to determine escalation and decide agentic tools to use. Agent decision layer → automatically triggers safety tools based on calculated risk and allowed rules. Implemented as a background Python application; no UI required for functionality.
Challenges we ran into
Handling LLM hallucination and making the system deterministic, so it does not overreact to neutral situations. Converting natural speech into accurate, meaningful risk signals. Balancing automation and false positives — ensuring the system only triggers tools when truly needed. Making the pipeline real-time while maintaining lightweight performance for background operation
Accomplishments that we're proud of
Built a fully autonomous safety agent that can make agentic decisions in real time. Integrated emotion and context analysis to go beyond just keyword spotting. Created a risk score system that strictly follows safety rules, avoiding hallucinations from LLMs. Implemented multiple automated safety tools that work without user intervention.
What we learned
How to combine traditional NLP + rule-based systems + LLM reasoning in a single pipeline. Real-world challenges of real-time risk assessment and autonomous decision making. Importance of deterministic AI in safety-critical applications. How to think like an “agent” AI that can act without explicit user commands.
What's next for Safety-Companion
Improve speech recognition accuracy for noisy environments. Add multi-modal sensing, e.g., video or motion detection, for better situational awareness. Optimize risk scoring and LLM reasoning to reduce latency. Explore mobile deployment so it can run on phones for real-life scenarios. Add user customization for trusted contacts, safety thresholds, and tool preferences.
Built With
- ollama
- python
Log in or sign up for Devpost to join the conversation.