Outsurance

Your Health, Your Privacy, No Fine Print.

Visit Repo
Outsurance banner

About

## The problem it solves

# The Problem Outsurance Solves

Buying health insurance in India is broken. For the average consumer, navigating the insurance landscape is a frustrating journey through deliberate jargon, hidden clauses, and high-pressure sales tactics. Outsurance re-engineers this experience from the ground up, turning a confusing financial chore into a transparent, secure, and hyper-personalized health strategy.

Here is exactly how Outsurance transforms the process, what people use it for, and how it makes existing tasks significantly easier, safer, and more accurate.

---

## 1. What Can People Use Outsurance For?

Outsurance serves as an autonomous, private digital insurance advisor. Users leverage the platform to: * **Audit Existing or New Plans:** Evaluate whether a health insurance plan genuinely covers their unique pre-existing conditions (e.g., Diabetes, Hypertension) before buying. * **Extract Vitals Automatically:** Upload complex medical reports, clinical PDFs, or lab blood tests to immediately extract critical health indicators without manually decoding medical terminology. * **Run Financial Stress Tests:** Simulate real-world medical emergencies (e.g., *"How much out-of-pocket cost will I pay if I am hospitalized for a heart attack in Mumbai under Plan X?"*). * **Interact with a Conversational Medical Agent:** Use natural language to query policy nuances, update health parameters on the fly, and ask follow-up questions like, *"What if I develop Asthma next year—how does that change my plan suitability?"* * **Navigate in Native Languages:** Break down complex financial and medical jargon into over 15+ local Indian languages for family members who are non-native English speakers.

---

## 2. Making Existing Tasks Easier: Frictionless Insurance Discovery

Traditional insurance platforms operate like basic filtering directories. Outsurance replaces manual searching with data-driven automation.

| Traditional Process | The Outsurance Way | How It Makes It Easier | | :--- | :--- | :--- | | **Manual Data Entry:** Spending 20 minutes manually entering old prescription dates, blood sugar levels, and BP readings. | **Local AI Extraction:** Uploading a lab report triggers a local Small Language Model (SLM) to extract vitals instantly. | **Saves Time & Eliminates Error:** Users don't need to know what "HbA1c" or "Systolic" means; the system inputs the data perfectly in seconds. | | **Deciphering Fine Print:** Reading 40-page policy PDFs to find waiting periods, co-pays, and disease-specific sub-limits. | **Structured Engine Matching:** Stage 2 & 3 matching algorithms cross-reference extracted health risks against a mapped database of insurance plans. | **Instant Clarification:** Zero scrolling through PDFs. The platform surfaces exact waiting periods and clauses relevant *only* to your conditions. | | **Opaque Recommendations:** Platforms show a "Best Seller" badge with zero explanation of why that plan fits you. | **Explainable AI (XGBoost + SHAP + Gemma):** Visualizes exactly how metrics like BMI or Age impacted your score, backed by a plain-English explanation. | **Informed Decision Making:** Removes guesswork. Users see exactly *why* a specific plan scored an 8.5/10 versus a 5/10. |

---

## 3. Making Existing Tasks Safer: Privacy & Integrity by Design

The current insurance market carries significant risks regarding data privacy and predatory marketing. Outsurance establishes a secure framework to eliminate these threats.

### 🚫 Stopping Spam & Eliminating Aggregator Leaks * **The Status Quo:** Entering your phone number on typical insurance aggregator sites instantly results in endless cold calls from aggressive brokers pushing high-commission plans. * **The Outsurance Safety:** Built with a strict **Zero-Knowledge Design**. Clinical document parsing runs entirely in local memory on the client side. Only 10 anonymous numeric health vitals pass through the Machine Learning pipeline. Your sensitive medical documents never touch a third-party server, keeping your personal contact information secure from broker databases.

### 🧠 Mitigating the "Underwriter Rejection" Trap * **The Status Quo:** Buying a plan without realizing a pre-existing condition is excluded can lead to claim rejections years later during a medical crisis. * **The Outsurance Safety:** By running an advanced **4-Stage ML Recommendation Pipeline** (utilizing a custom XGBoost classifier trained on real hospital survey data), the platform calculates an accurate health risk tier (Low to Critical) beforehand. It proactively flags hidden policy traps, exclusions, and co-payment clauses before you pay a single rupee in premiums.

### 🔒 Secure Data Control

* Backed by rigid database **Row-Level Security (RLS)** and stateless JWT tokens, user sessions are completely isolated. For high-security environments, the entire ecosystem is packaged to deploy entirely offline on edge hardware (like a Raspberry Pi kiosk), ensuring sensitive medical queries can happ

## Challenges we ran into

# Challenges We Ran Into

Building a production-ready, local-first intelligence engine that couples deterministic machine learning pipelines with non-deterministic small language models presented several technical hurdles. Because we chose to deploy on resource-constrained hardware (Raspberry Pi) and enforce absolute client-side data isolation, we could not rely on standard cloud infrastructure solutions.

Here are the major technical challenges we encountered during development and how we engineered our way around them.

---

### 1. The Small Language Model Context Bloat & Multi-Agent Loop * **The Hurdle:** Our conversational chatbot (`backend/app/agent.py`) handles complex tasks like tool orchestration, running out-of-pocket stress tests, and comparing plan specifications stored in `plans_db.py`. When we used local `gemma3:1b` via Ollama to evaluate conversational context alongside policy features for multiple plans, the context token count bloated immediately. This caused massive response latency (over 45 seconds per turn) on local hardware and occasionally led the model into an infinite loop of calling the same tool repeatedly. * **How We Got Over It:** We engineered a **State-Throttled Tool Router**. Instead of passing raw, unstructured policy data or the entire chat history back to the model, we decoupled the execution layers: 1. We used the local SLM strictly as a lightweight **Intent and Named Entity Recognition (NER) extractor** to pull parameters (e.g., condition names, localized budget ceilings). 2. We passed these parsed parameters into deterministic, fast Python utility modules (`hospital_network.py` and `stress_test.py`). 3. The structured responses from these modules were then injected into an optimized, minimal prompt template. This reduced the token payload by **78%**, dropping latency to under 3 seconds on standard local machines.

---

### 2. Feature Asymmetry & Normalization Breakdown in the XGBoost Pipeline * **The Hurdle:** Stage 1 of our recommendation pipeline relies on a custom XGBoost classification model to assess a user's health risk tier based on real medical vitals (such as HbA1c, systolic blood pressure, and BMI). During testing, we noticed that when users had high qualitative medical risks (e.g., a history of severe kidney stones or a recent major surgical event) but otherwise perfect quantitative vitals (normal blood pressure, low BMI), the XGBoost model completely ignored the qualitative medical history and classified them as "Low Risk." This resulted in dangerous plan mismatches. * **How We Got Over It:** We introduced **Stage 0: The Dynamic Condition Scorer** (`condition_scorer.py`). Before passing data to the XGBoost matrix, any text-based medical history or parsed clinical report details are processed through a local, aggressively cached risk-weight map (scoring conditions from `0.0` to `5.0`). We engineered a synthetic interaction feature—`metabolic_risk_score`—which cross-multiplies this condition score against quantitative biometric markers. By including this engineered feature in our training dataset, the XGBoost model learned to identify complex interactions, boosting classification accuracy to **85.0%** across all risk tiers.

---

### 3. RAM Swapping & Quantization Bottlenecks on Edge Deployments * **The Hurdle:** One of our primary objectives was enabling the entire platform to execute entirely offline on a Raspberry Pi. During initial edge runs, launching the FastAPI backend alongside Ollama loading the `gemma3:1b` weights caused immediate memory starvation on the Pi's RAM. The operating system began aggressive memory swapping, which stalled the UI and caused the local AI document-extraction step to crash with out-of-memory (OOM) errors. * **How We Got Over It:** We resolved this hardware bottleneck through aggressive resource optimizations: 1. We switched to an aggressively quantized GGUF variant of the model, strictly limiting its execution footprint. 2. We configured a strict memory-concurrency lock in the backend code, ensuring that the heavy extraction phase, the XGBoost inference matrix, and the chat agent never execute simultaneously in memory. 3. We built a native **Soft-Fail Engine** that actively monitors hardware overhead. If local system resources cross a critical 92% RAM utilization threshold, the platform cleanly falls back to a high-speed regex-based medical parsing engine and static model matrix, preventing hardware lockups while preserving core platform features.

Team

From the public Devfolio project page. Votes, swipes and the judge score are hackfeed's own.

AI judge

Not judged yet. A free model reads this page, compares it with similar projects and this event's winners, then scores it and says what would make it win.

Still being built?

Not checked yet.

Swipe stats

0upvotes
0skips
0saves

Discussion 0

No comments yet. Ask the team something, or say what you'd use it for.

Posting as a guest. Plain text, 1,000 characters max.

Already built nearby

Closest projects by meaning and shared words. Similar isn't the same as copied: read them.