## PharmaSense AI
💡 Inspiration
Pharmaceutical environments like cold storage units, drug dispensers, and blood banks operate under strict safety and compliance requirements. Even minor failures—such as compressor breakdowns, power outages, or sensor drift—can silently destroy critical medical inventory before humans can respond.
We built PharmaSense AI after realizing that most monitoring systems are reactive rather than proactive, and lack intelligent triage that can prioritize risk, explain decisions, and ensure compliance readiness.
🚀 What it does
PharmaSense AI is an AI-powered autonomous triage system for pharmaceutical infrastructure monitoring.
It continuously analyzes simulated equipment telemetry and:
Detects anomalies and predicts potential failures Classifies events into risk levels (LOW → CRITICAL) Generates structured decision outputs (risk level, explanation, action plan) Escalates critical cases through human-in-the-loop approval workflows Logs every decision into Splunk for auditability and compliance
The system is designed to be offline-first, ensuring reliability even when external AI services are unavailable.
⚙️ How we built it
We designed a modular AI orchestration pipeline centered around a core triage loop:
Telemetry Simulation Layer: Generates realistic pharmaceutical equipment events Orchestrator Engine (run_triage_loop): Core decision-making system Predictive Failure Module (predict_failure): Estimates risk before failure occurs LLM Decisioning (Gemini integration): Enhances reasoning when available Deterministic Fallback Logic: Ensures safe decisions without cloud dependency Human-in-the-Loop Alerts (send_hitl_alert): Escalates critical cases Observability Layer (_log_to_splunk_hec): Sends structured logs to Splunk HEC
We also built an integration testing system validating end-to-end behavior across multiple simulated devices and failure scenarios.
🧪 Key Scenarios Demonstrated FZ-01: Compressor Failure → CRITICAL escalation + approval required FZ-04: Power Loss → system continuity with fallback triage DD-01: Access Anomaly → security event detection and escalation
Each scenario produces a structured response:
risk_level requires_human_approval approval_message action_plan
🧩 Challenges we ran into Balancing LLM-based reasoning with deterministic safety logic Designing reliable fallback behavior when external APIs fail Structuring consistent decision schemas across heterogeneous failure types Ensuring observability and auditability through Splunk integration
🏆 Accomplishments Built a fully autonomous AI triage pipeline Implemented offline-first decisioning for reliability Integrated predictive + reactive failure detection Created structured compliance-grade decision outputs Achieved end-to-end observability via Splunk logging
📚 What we learned
We learned how to design safe AI systems for regulated environments, where correctness and auditability matter more than raw intelligence. We also gained experience in building hybrid architectures combining LLM reasoning with deterministic fallback systems.
🔮 What's next Real hardware integration with IoT pharmaceutical sensors Advanced forecasting models for predictive maintenance Role-based dashboards for hospital administrators Expanded compliance reporting modules Production-grade deployment with live telemetry streams
🧠 Impact
PharmaSense AI enables proactive pharmaceutical safety infrastructure, ensuring that critical failures are detected early, explained clearly, and logged transparently.
Even when AI services are unavailable, the system continues to operate safely—making it suitable for high-stakes healthcare environments where reliability is non-negotiable.
Built With
- decision-tree
- gemini-api
- offline-default-data
- orchestrator
- simulation
- splunk
Log in or sign up for Devpost to join the conversation.