Inspiration

Hospitals generate massive amounts of operational data every day, yet many critical issues such as medicine shortages, staffing overload, and operational bottlenecks are still discovered too late. Teams often rely on manual monitoring, spreadsheets, and reactive workflows, leading to delayed responses and potential impacts on patient care.

We wanted to build a system that continuously monitors hospital operations, automatically detects risks, and proactively notifies stakeholders before problems become critical.

That's how Octogram was born.

What It Does

Octogram is an autonomous AI-powered hospital operations monitoring platform.

It continuously analyzes operational data flowing through hospital systems and automatically identifies high-priority risks.

Examples include:

  • Medicine stockout predictions
  • Supply chain disruptions
  • Staffing overload risks
  • Operational delays
  • Revenue-impacting anomalies

When risks are detected, Octogram automatically:

  1. Generates operational alerts
  2. Prioritizes alerts by severity
  3. Updates the operations dashboard
  4. Sends Telegram notifications to stakeholders
  5. Provides AI-powered operational insights

How We Built It

Our architecture combines modern data infrastructure with AI-driven monitoring.

Hospital ERP data is stored in PostgreSQL and synchronized to Google BigQuery using Fivetran.

After every successful sync, Fivetran triggers a webhook that activates the Octogram Alert Agent.

The agent:

  • Analyzes newly synchronized data
  • Computes operational risks
  • Generates or updates alerts
  • Sends critical notifications through Telegram
  • Makes alerts available through the Next.js dashboard

The frontend is built with Next.js, TypeScript, Tailwind CSS, and shadcn/ui.

The AI layer uses Ollama with Gemma for operational summaries and natural language analysis.

Challenges We Ran Into

One of the biggest challenges was building a reliable event-driven workflow.

We needed to ensure that:

  • Fivetran syncs could automatically trigger downstream processing
  • Alert generation did not create duplicate alerts
  • Resolved and dismissed alerts were preserved correctly
  • Real-time notifications remained synchronized with operational data

We also worked through webhook integration, BigQuery permissions, Telegram bot integration, and maintaining consistent alert states across the system.

Another significant challenge was integrating local AI inference into the workflow. Initially, we explored cloud-hosted models, but API limitations and billing constraints led us to adopt Ollama with Gemma. This required designing the application so that operational summaries and natural language insights could be generated reliably while keeping the architecture flexible enough to support both local and cloud-based AI models in the future.

Balancing operational accuracy, real-time responsiveness, and a clean user experience required multiple iterations across the data pipeline, alert engine, and AI reasoning layer.

Accomplishments We're Proud Of

We're proud of building a fully automated operational monitoring pipeline.

A successful Fivetran sync now automatically:

  • Updates BigQuery
  • Triggers the Octogram Agent
  • Generates operational alerts
  • Updates the dashboard
  • Sends Telegram notifications

without requiring manual intervention.

What We Learned

This project taught us how to combine modern data pipelines, event-driven architectures, AI agents, and operational monitoring into a single intelligent workflow.

We gained hands-on experience with:

  • Fivetran Webhooks
  • Google BigQuery
  • AI-powered operational reasoning
  • Real-time notification systems
  • Agent-driven automation

What's Next For Octogram

While this demo focuses on medicine stockouts and operational alerts, the same architecture can monitor virtually any hospital workflow.

Future versions will support:

  • Predictive procurement recommendations
  • Automated scheduling assistance
  • Multi-hospital monitoring
  • Supply chain intelligence
  • BigQuery ML forecasting
  • Executive operational reporting

Our vision is to transform hospital operations from reactive monitoring to proactive intelligence through autonomous AI agents.

Built With

Share this project:

Updates

posted an update

To keep the project cost-efficient and fully self-hosted, Octogram currently uses Ollama + Gemma for AI-powered operational insights instead of cloud-hosted LLM APIs.

The AI assistant is available primarily for demo purposes, while the core workflow remains fully functional:

✅ Fivetran → BigQuery synchronization ✅ Automated alert generation ✅ Telegram notifications ✅ Hospital operations dashboard

Note: Some integrations currently rely on trial services such as Fivetran, which are demonstrated in the submission video.

Log in or sign up for Devpost to join the conversation.