

Democratizing health insurance decision-making through open-source tools
Health insurance is one of the most important financial decisions families make, yet the tools to analyze and compare policies are either:
- Locked behind commercial paywalls π
- Built for brokers, not consumers πΌ
- Overly simplified and unhelpful π
- Biased toward specific insurers π―
Open Coverage changes this. We're building the first truly open-source ecosystem of health insurance tools that put consumers first. No vendor lock-in, no hidden agendas, no subscription feesβjust powerful, transparent tools that help you make the best healthcare decisions for your family.
To make health insurance analysis accessible, transparent, and free for everyone.
We believe that:
- π Healthcare decisions should be transparent - You deserve to understand exactly how your policy works
- π οΈ Tools should be built by and for the community - Open source means accountable, improvable software
- π° Essential services shouldn't cost extra - Healthcare is expensive enough without paying for analysis tools
- π― Consumer interests come first - No insurer partnerships or broker commissions influencing recommendations
Our flagship tool - Upload your health insurance policy documents (Summary of Benefits and Coverage) and get:
- π Complete policy breakdown - Every benefit, clearly explained
- π Side-by-side comparisons - Multiple policies analyzed simultaneously
- π₯ Personalized recommendations - Based on your family's actual health profile
- π‘ Cost projections - Estimate your total annual healthcare expenses
- π€ AI-powered insights - Ask questions about your coverage in plain English
- Upload your insurance policy documents (SBC/SPD files)
- Configure your family's health profile (conditions, medications, expected visits)
- Analyze - Our AI processes your documents and health needs
- Compare - See which policy saves you the most money
- Decide with confidence, backed by data
- Next.js 15 with App Router
- TypeScript for type safety
- Tailwind CSS + shadcn/ui for beautiful interfaces
- Anthropic Claude & Groq for intelligent document analysis
- @assistant-ui/react for AI chat interface
- Zustand for state management
- Zod for schema validation
- PDF parsing for document processing
- Vercel for deployment
- Bun for fast JS runtime & package management
app/
βββ actions/ # Server actions for AI operations
βββ analysis/ # Policy analysis pages
βββ analyze-compare/ # Policy comparison interface
βββ analyze-compare-v2/ # Enhanced comparison interface
βββ analyze-policy/ # Single policy analysis
βββ api/ # API endpoints
β βββ analyze-health-profile/
β βββ chat/ # AI-powered chat endpoint
β βββ health-suggestions/
β βββ search-treatment-cost/
β βββ treatment-costs/
βββ compare-policies/ # Policy comparison tools
βββ cost-analysis/ # Healthcare cost analysis
βββ find-providers/ # Provider discovery
βββ health-profile/ # Family health management
βββ assistant.tsx # AI chat component
βββ error.tsx # Error handling pages
βββ global-error.tsx # Global error boundary
βββ layout.tsx # Root layout
βββ not-found.tsx # 404 page
βββ page.tsx # Homepage
components/
βββ app-sidebar.tsx # Navigation sidebar
βββ assistant-ui/ # Chat interface components
βββ error-boundaries/ # Error handling components
βββ health-profile/ # Health profile components
βββ ui/ # Reusable UI components (shadcn)
βββ policy-*.tsx # Policy-specific components
βββ cost-analysis-summary.tsx
βββ healthcare-information-modal.tsx
βββ premium-input-modal.tsx
βββ profile-completeness.tsx
βββ risk-assessment-display.tsx
βββ treatment-cost-display.tsx
βββ utilization-display.tsx
lib/
βββ services/ # Business logic and AI operations
β βββ insurance-ai-service.ts
β βββ policy-comparison-service.ts
β βββ policy-service.ts
βββ hooks/ # Utility hooks
β βββ use-health-ai.ts
β βββ use-screen-reader.tsx
β βββ use-treatment-costs.ts
βββ analysis-store.ts # Analysis state management
βββ enhanced-health-profile-store.ts
βββ health-profile-store.ts
βββ health-risk-assessment.ts
βββ insurance-calculator.ts
βββ medication-cost-calculator.ts
βββ pdf-utils.ts # Document processing
βββ sbc-schema.ts # Insurance document schemas
βββ treatment-cost-service.ts
βββ unified-analysis-service.ts
βββ utilization-engine.ts
hooks/
βββ use-category-analysis.ts # AI category management
βββ use-comparison-history.ts # Comparison history
βββ use-healthcare-information.ts
βββ use-insurance-settings.ts # Centralized settings
βββ use-mobile.ts # Mobile detection
βββ use-situation-suggestions.ts # Healthcare suggestions
βββ use-toast.ts # Toast notifications
types/
βββ schemas.ts # Consolidated Zod schemas
βββ insurance.ts # Type definitions
policy-templates/ # Sample policy templates
__tests__/ # Test files
The project follows a service-layer architecture pattern:
- Service Layer First: All AI operations go through
lib/services/
- Type Safety: Zod schemas for all validation and type generation
- Error Boundaries: Graceful degradation with
AIErrorBoundary
components - Custom Hooks: Single responsibility hooks for business logic
- Multi-Model AI: Fallback strategies with Anthropic Claude and Groq models
- Bun (recommended) or Node.js 20+
- API keys for Groq, Anthropic (for AI features)
# Clone the repository
git clone https://github.com/aaln/open-coverage.git
cd open-coverage
# Install dependencies
bun install
# Set up environment variables
cp .env.example .env.local
# Add your API keys to .env.local (see Environment Variables section below)
# Start development server
bun run dev
Visit http://localhost:3000
to see the app running.
bun run dev # Start development server
bun run build # Build for production
bun run start # Start production server
bun run lint # Run linter
bun run fetch:plans # Fetch sample insurance plans
Create a .env.local
file in the root directory with the following variables:
# AI Model APIs
GROQ_API_KEY= # For Groq AI models
ANTHROPIC_API_KEY= # For Claude models
# Document Processing
UNSTRUCTURED_API_KEY= # For PDF parsing
# Storage & Background Jobs
BLOB_READ_WRITE_TOKEN= # For file storage
TRIGGER_SECRET_KEY= # For background jobs
# CMS.gov APIs (optional - for discovery features)
GOV_MARKETPLACE_API_KEY= # For Marketplace API
GOV_FINDER_API_KEY= # For Finder API
Note: The discovery section of the site won't work if these keys aren't available.
To get API keys for the CMS Healthcare APIs:
-
Visit CMS Developer Portal
-
Click "Sign Up" to create a CMS Enterprise Portal account
-
For Marketplace API (GOV_MARKETPLACE_API_KEY):
- Navigate to "Marketplace API" section
- Click "Request Access"
- Fill out the application form
- Submit and await approval
-
For Finder API (GOV_FINDER_API_KEY):
- Navigate to "Finder API" section
- Click "Request Access"
- Complete similar application process
- Specify intended usage for finding private health plans
We welcome contributions from developers, healthcare professionals, insurance experts, and anyone passionate about making healthcare more accessible!
- π Report bugs - Found an issue? Let us know!
- π‘ Suggest features - Have ideas for improvement?
- π Improve documentation - Help others understand the project
- π§ Submit code - Fix bugs or add new features
- π§ͺ Test policies - Try the tool with different insurance documents
- π’ Spread the word - Help others discover Open Coverage
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Make your changes
- Test thoroughly
- Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project includes comprehensive Cursor IDE rules for enhanced development experience. The .cursor/rules/
directory contains:
- Global Rules - Core development standards and architecture patterns
- Server Actions - Guidelines for Next.js server actions
- Self-Updating Rules - Dynamic rule system that adapts to project changes
- Build Agent - Automated build, linting, and formatting
- β SBC Document Processing - Parse Summary of Benefits and Coverage documents
- β Health Profile Management - Store family health information securely
- β AI Chat Interface - Ask questions about your insurance in natural language
- β Policy Comparison - Side-by-side analysis of multiple policies
- β Responsive Design - Works on desktop, tablet, and mobile
- β Privacy-First - All data stored locally in your browser
- Local-first - Your health data never leaves your device
- No tracking - We don't collect personal information
- Open source - Audit our code anytime
- No vendor lock-in - Export your data whenever you want
This project is licensed under the MIT License - see the LICENSE file for details.
Together, we're making healthcare decisions more transparent, accessible, and affordable for everyone.