AI-powered cardiology pre-screening assistant for the Polish healthcare system. Conducts structured medical interviews and generates comprehensive triage reports for cardiologists.
- Two-phase interview flow: Predefined cardiology questions followed by AI-generated follow-ups
- Multi-provider LLM support: OpenAI (including ChatGPT-5), Anthropic Claude, Azure OpenAI
- Professional reports: On-screen display with PDF export
- Polish language: All content in Polish, following gov.pl design system
- Configurable prompts: Edit AI prompts in
prompts.jsonwithout code changes - Patient demographics: Collects sex and age for risk-adjusted analysis
# Install dependencies
npm install
# Start development server
npm run devOpen http://localhost:3000 in your browser.
Click the settings icon in the header to configure:
- Select provider (OpenAI, Anthropic, or Azure)
- Enter your API key
- Choose model (ChatGPT-5, GPT-4o, Claude Sonnet 4, etc.)
- Test connection and save
No environment variables required - settings are stored in browser localStorage.
# .env.local
# Supabase (optional)
NEXT_PUBLIC_SUPABASE_URL=...
NEXT_PUBLIC_SUPABASE_ANON_KEY=...
# Default LLM fallback
LLM_PROVIDER=openai
LLM_API_KEY=sk-...
LLM_MODEL=gpt-4o- Enter patient data: ID, sex, age
- Phase 1: Answer 30+ predefined cardiology questions
- AI Analysis: System generates personalized follow-up questions
- Phase 2: Answer 3-8 follow-up questions
- Report: View and download PDF report for cardiologist
src/
├── app/
│ ├── page.tsx # Landing page
│ ├── interview/page.tsx # Interview flow
│ ├── report/page.tsx # Report display
│ └── api/ # API routes
├── components/ui/ # UI components
├── lib/
│ ├── prompts.json # All AI prompts (editable)
│ ├── questions/ # Predefined questions
│ ├── llm/ # LLM provider abstraction
│ └── store.ts # Zustand state
└── types/ # TypeScript types
Edit src/lib/prompts.json to modify AI behavior:
{
"analysis": {
"system": "...", // Cardiologist analysis prompt
"userTemplate": "..."
},
"report": {
"system": "...", // Report generation prompt
"userTemplate": "..."
}
}Based on:
- ESC Guidelines (European Society of Cardiology)
- ASCVD/EZ-CVD Risk Calculators
- Polish medical interview standards (wywiad lekarski)
- Framework: Next.js 16 (App Router)
- Styling: Tailwind CSS (gov.pl design system)
- State: Zustand
- PDF: jsPDF
- LLM: OpenAI / Anthropic / Azure APIs
npm run dev # Development server
npm run build # Production build
npm run start # Start production
npm run lint # ESLintMIT