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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
title: HelloFibro
|
| 3 |
+
emoji: π
|
| 4 |
+
colorFrom: red
|
| 5 |
+
colorTo: yellow
|
| 6 |
+
sdk: gradio
|
| 7 |
+
sdk_version: 6.15.1
|
| 8 |
+
app_file: app.py
|
| 9 |
+
python_version: "3.12"
|
| 10 |
+
startup_duration_timeout: 1h
|
| 11 |
+
suggested_hardware: zero-a10g
|
| 12 |
+
short_description: Multimodal fibromyalgia support with MedGemma
|
| 13 |
+
models:
|
| 14 |
+
- google/medgemma-27b-it
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
<p align="center">
|
| 18 |
+
<img width="250" height="250" alt="logo" src="https://github.com/user-attachments/assets/c2ad2088-729e-4257-9793-2f96f49053b0" />
|
| 19 |
+
</p>
|
| 20 |
+
|
| 21 |
+
<p align="center">
|
| 22 |
+
<strong>AI-powered support companion for people living with fibromyalgia</strong>
|
| 23 |
+
</p>
|
| 24 |
+
|
| 25 |
+
<p align="center">
|
| 26 |
+
<a href="#-features">Features</a> β’
|
| 27 |
+
<a href="#-demo">Demo</a> β’
|
| 28 |
+
<a href="#-quick-start">Quick Start</a> β’
|
| 29 |
+
<a href="#-tech-stack">Tech Stack</a> β’
|
| 30 |
+
<a href="#-architecture">Architecture</a> β’
|
| 31 |
+
<a href="#-workflows">Workflows</a>
|
| 32 |
+
</p>
|
| 33 |
+
|
| 34 |
+
<p align="center">
|
| 35 |
+
<img src="https://img.shields.io/badge/Python-3.10+-3776AB?style=for-the-badge&logo=python&logoColor=white" alt="Python">
|
| 36 |
+
<img src="https://img.shields.io/badge/Gradio-6.0-FF7C00?style=for-the-badge&logo=gradio&logoColor=white" alt="Gradio">
|
| 37 |
+
<img src="https://img.shields.io/badge/Claude-Sonnet_4-191919?style=for-the-badge&logo=anthropic&logoColor=white" alt="Claude">
|
| 38 |
+
|
| 39 |
+
</p>
|
| 40 |
+
|
| 41 |
+
<p align="center">
|
| 42 |
+
<img src="https://img.shields.io/badge/UI-Art_Deco_Inspired-8B0000?style=flat-square" alt="Art Deco">
|
| 43 |
+
<img src="https://img.shields.io/badge/Accessibility-WCAG_AA-D4AF37?style=flat-square" alt="WCAG AA">
|
| 44 |
+
<img src="https://img.shields.io/badge/Languages-21_Supported-white?style=flat-square" alt="21 Languages">
|
| 45 |
+
</p>
|
| 46 |
+
|
| 47 |
+
---
|
| 48 |
+
|
| 49 |
+
## π About
|
| 50 |
+
|
| 51 |
+
**HelloFibro** is an AI assistant designed specifically for people living with fibromyalgia. It provides emotional support, evidence-based information, practical coping strategies, and medication managementβall through a beautiful, accessible interface optimized for those experiencing chronic pain and fatigue.
|
| 52 |
+
|
| 53 |
+
### Why HelloFibro?
|
| 54 |
+
|
| 55 |
+
Living with fibromyalgia means dealing with invisible symptoms that others often don't understand. HelloFibro was built with deep empathy and understanding:
|
| 56 |
+
|
| 57 |
+
- π **Validation First** β Your pain is real. Your experiences matter.
|
| 58 |
+
- π§ **Brain Fog Friendly** β Clear, simple interface designed for cognitive challenges
|
| 59 |
+
- π **Gentle Design** β Art Deco-inspired aesthetics that are calming, not overwhelming
|
| 60 |
+
- π **21 Languages** β Full internationalization with native language support
|
| 61 |
+
- π **Privacy Focused** β No data persistence, session-only storage
|
| 62 |
+
|
| 63 |
+
---
|
| 64 |
+
|
| 65 |
+
## π¬ Demo
|
| 66 |
+
|
| 67 |
+
https://github.com/user-attachments/assets/4f57d250-8355-4167-927e-f14fa78e8a6e
|
| 68 |
+
|
| 69 |
+
The hosted MedGemma version is a research/portfolio demonstration, not a
|
| 70 |
+
medical device or healthcare service. Chat access is gated by acceptance of the
|
| 71 |
+
[HelloFibro HAI-DEF Demo Use Terms](docs/HAI_DEF_DEMO_TERMS.md), which
|
| 72 |
+
incorporate Google's
|
| 73 |
+
[HAI-DEF Terms of Use](https://developers.google.com/health-ai-developer-foundations/terms)
|
| 74 |
+
and
|
| 75 |
+
[Prohibited Use Policy](https://developers.google.com/health-ai-developer-foundations/prohibited-use-policy).
|
| 76 |
+
|
| 77 |
+
---
|
| 78 |
+
|
| 79 |
+
## β¨ Features
|
| 80 |
+
|
| 81 |
+
### π¬ Empathetic AI Chat
|
| 82 |
+
|
| 83 |
+
The heart of HelloFibroβintelligent, understanding conversations powered by Claude Sonnet 4.
|
| 84 |
+
|
| 85 |
+
| Feature | Description |
|
| 86 |
+
|---------|-------------|
|
| 87 |
+
| **Streaming Responses** | Real-time typing effect for natural conversation flow |
|
| 88 |
+
| **Fibromyalgia Expertise** | Specialized knowledge about symptoms, triggers, and management |
|
| 89 |
+
| **Session Memory** | Remembers context within your conversation |
|
| 90 |
+
| **Markdown Support** | Rich formatting for clear, readable responses |
|
| 91 |
+
| **Brain Fog Consideration** | Short paragraphs, clear language, patient pacing |
|
| 92 |
+
| **Medical Context Awareness** | Automatically detects worsening factors in your messages |
|
| 93 |
+
| **EULAR 2016 Compliance** | Recommendations align with EU clinical guidelines |
|
| 94 |
+
|
| 95 |
+
```
|
| 96 |
+
User: Mam dziΕ bardzo silny bΓ³l i nie wiem co robiΔ
|
| 97 |
+
|
| 98 |
+
HelloFibro: π Bardzo mi przykro, ΕΌe mierzysz siΔ dziΕ z takim silnym bΓ³lem.
|
| 99 |
+
To musi byΔ naprawdΔ trudne.
|
| 100 |
+
|
| 101 |
+
Kilka rzeczy, ktΓ³re mogΔ
pomΓ³c w tej chwili:
|
| 102 |
+
β’ ZnajdΕΊ wygodnΔ
pozycjΔ i pozwΓ³l sobie odpoczΔ
Δ
|
| 103 |
+
β’ CiepΕy okΕad moΕΌe przynieΕΔ ulgΔ
|
| 104 |
+
β’ Spokojne, gΕΔbokie oddychanie...
|
| 105 |
+
```
|
| 106 |
+
|
| 107 |
+
### π Medication Management
|
| 108 |
+
|
| 109 |
+
Comprehensive medication tracking designed for chronic illness management.
|
| 110 |
+
|
| 111 |
+
| Feature | Description |
|
| 112 |
+
|---------|-------------|
|
| 113 |
+
| **Quick Add** | Add medications via chat or form interface |
|
| 114 |
+
| **Visual Tracking** | See all medications with taken/pending status |
|
| 115 |
+
| **One-Tap Logging** | Mark medications as taken with a single click |
|
| 116 |
+
| **Missed Dose Alerts** | Smart notifications for missed doses after 4 AM |
|
| 117 |
+
| **Reminder Toggle** | Enable/disable reminders per medication |
|
| 118 |
+
| **Adherence Stats** | Track your medication compliance |
|
| 119 |
+
|
| 120 |
+
#### β οΈ Missed Dose Notification
|
| 121 |
+
|
| 122 |
+
When you miss a medication dose, HelloFibro will remind you the next morning (after 4:00 AM) with a gentle notification:
|
| 123 |
+
|
| 124 |
+
| Action | Description |
|
| 125 |
+
|--------|-------------|
|
| 126 |
+
| **β WziΔty** | Mark as taken late (still counts for adherence) |
|
| 127 |
+
| **β PominiΔty** | Register as missed dose |
|
| 128 |
+
| **OdrzuΔ** | Dismiss notification without logging |
|
| 129 |
+
|
| 130 |
+
The notification uses calming amber colors (not aggressive red) following healthcare UX best practices for reduced alert fatigue.
|
| 131 |
+
|
| 132 |
+
**Supported medication categories:**
|
| 133 |
+
- Fibromyalgia/Neuropathic (Pregabalin, Duloxetine, Gabapentin...)
|
| 134 |
+
- NSAIDs (Ibuprofen, Ketoprofen, Naproxen...)
|
| 135 |
+
- Stronger painkillers (Tramadol, Tapentadol...)
|
| 136 |
+
- Muscle relaxants (Tizanidine, Baclofen...)
|
| 137 |
+
- Sleep aids (Melatonin, Trazodone...)
|
| 138 |
+
- Supplements (Magnesium, Vitamin D3, CBD oil...)
|
| 139 |
+
|
| 140 |
+
### π
Appointment Management
|
| 141 |
+
|
| 142 |
+
Track and manage your doctor appointments with smart reminders.
|
| 143 |
+
|
| 144 |
+
| Feature | Description |
|
| 145 |
+
|---------|-------------|
|
| 146 |
+
| **Add Appointments** | Schedule visits with doctor name, specialty, date/time, location |
|
| 147 |
+
| **Specialty Types** | Pre-defined medical specialties (Rheumatologist, Neurologist, etc.) |
|
| 148 |
+
| **Visual Tracking** | See upcoming appointments with status indicators |
|
| 149 |
+
| **Smart Reminders** | Optional day-before reminder notifications |
|
| 150 |
+
| **Notes** | Add questions and notes for each appointment |
|
| 151 |
+
| **Status Indicators** | Today, Soon, Upcoming, Past appointment badges |
|
| 152 |
+
|
| 153 |
+
**Medical use cases:**
|
| 154 |
+
- Schedule rheumatologist follow-ups
|
| 155 |
+
- Track physiotherapy sessions
|
| 156 |
+
- Prepare questions for specialist visits
|
| 157 |
+
- Never miss important appointments
|
| 158 |
+
|
| 159 |
+
### π File Analysis
|
| 160 |
+
|
| 161 |
+
Upload and discuss medical documents with AI assistance.
|
| 162 |
+
|
| 163 |
+
| File Type | Supported Formats | Capabilities |
|
| 164 |
+
|-----------|-------------------|--------------|
|
| 165 |
+
| **Documents** | PDF, DOCX, DOC | Extract text, find key health info |
|
| 166 |
+
| **Spreadsheets** | XLSX, XLS, CSV | Analyze symptoms, patterns, statistics |
|
| 167 |
+
| **Text Files** | TXT, MD, JSON, XML, LOG | Parse and explain content |
|
| 168 |
+
| **Images** | PNG, JPG, GIF, WEBP | Describe and discuss |
|
| 169 |
+
| **Code** | PY, JS, HTML, CSS | Explain and analyze |
|
| 170 |
+
|
| 171 |
+
**Medical use cases:**
|
| 172 |
+
- π Prescription analysis
|
| 173 |
+
- π Symptom diary review
|
| 174 |
+
- π©Ί Lab results discussion
|
| 175 |
+
- π Doctor visit preparation
|
| 176 |
+
|
| 177 |
+
### π§ Medical Intelligence Layer
|
| 178 |
+
|
| 179 |
+
Advanced AI-powered medical reasoning system for evidence-based fibromyalgia support.
|
| 180 |
+
|
| 181 |
+
| Component | Description |
|
| 182 |
+
|-----------|-------------|
|
| 183 |
+
| **Adaptive Reasoning Router** | Routes queries to appropriate reasoning depth based on complexity |
|
| 184 |
+
| **Medical Knowledge Service** | Queries 15+ worsening factors, EULAR guidelines, differential diagnosis |
|
| 185 |
+
| **EU Guidelines Validator** | Validates recommendations against EULAR 2016, German S3, UK NICE |
|
| 186 |
+
| **FHIR Patient Profile** | HL7 FHIR R4-compliant patient model with ACR 2016 criteria |
|
| 187 |
+
| **Agent Council** | Multi-agent system with backtracking exploration for complex cases |
|
| 188 |
+
|
| 189 |
+
#### Reasoning Modes
|
| 190 |
+
|
| 191 |
+
| Mode | Complexity | Use Case |
|
| 192 |
+
|------|------------|----------|
|
| 193 |
+
| **Parallel Short** | < 0.3 | Simple symptom questions, medication lookup |
|
| 194 |
+
| **Sequential Medium** | 0.3-0.7 | Symptom pattern analysis, treatment comparison |
|
| 195 |
+
| **Deep Sequential** | > 0.7 | Differential diagnosis, treatment-resistant cases |
|
| 196 |
+
|
| 197 |
+
#### Medical Knowledge Base
|
| 198 |
+
|
| 199 |
+
- **15 Worsening Factors** with severity scores, mechanisms, and neurotransmitter impacts
|
| 200 |
+
- **EULAR 2016 Recommendations** β Strong FOR, Weak FOR, Strong AGAINST
|
| 201 |
+
- **German S3 & UK NICE Guidelines** β First-line treatments, contraindications
|
| 202 |
+
- **Differential Diagnosis** β Lyme, hypothyroidism, vitamin D deficiency, ACR 2016 criteria
|
| 203 |
+
- **Medication Database** β EU/FDA approval status, response rates, contraindications
|
| 204 |
+
|
| 205 |
+
#### Automatic Factor Detection
|
| 206 |
+
|
| 207 |
+
The system detects worsening factors mentioned in your messages:
|
| 208 |
+
|
| 209 |
+
```
|
| 210 |
+
User: "I can't sleep and I'm very stressed lately"
|
| 211 |
+
|
| 212 |
+
Detected Factors:
|
| 213 |
+
- sleep_deprivation (sleep, insomnia keywords)
|
| 214 |
+
- hpa_axis_dysregulation (stress, anxiety keywords)
|
| 215 |
+
|
| 216 |
+
β Enhanced response with relevant coping strategies
|
| 217 |
+
```
|
| 218 |
+
|
| 219 |
+
### π Multi-Language Support
|
| 220 |
+
|
| 221 |
+
Full internationalization with 21 supported languages.
|
| 222 |
+
|
| 223 |
+
| Region | Languages |
|
| 224 |
+
|--------|-----------|
|
| 225 |
+
| **Europe** | English (US/UK), Polish, German, Spanish, French, Italian, Dutch, Portuguese, Swedish, Norwegian, Danish |
|
| 226 |
+
| **Asia** | Japanese, Korean, Chinese, Thai, Indonesian, Hindi |
|
| 227 |
+
| **Middle East** | Arabic, Hebrew, Turkish |
|
| 228 |
+
|
| 229 |
+
**Features:**
|
| 230 |
+
- Language selector in the UI sidebar
|
| 231 |
+
- All UI elements fully translated
|
| 232 |
+
- Automatic fallback to English for missing translations
|
| 233 |
+
- Easy to add new languages via JSON translation files
|
| 234 |
+
|
| 235 |
+
### π¨ Premium Design
|
| 236 |
+
|
| 237 |
+
Art Deco-inspired healthcare aesthetic that's both beautiful and functional.
|
| 238 |
+
|
| 239 |
+
| Design Element | Details |
|
| 240 |
+
|----------------|---------|
|
| 241 |
+
| **Primary Color** | Deep Crimson `#8B0000` β trust, medical seriousness |
|
| 242 |
+
| **Accent Color** | Warm Gold `#D4AF37` β premium, hopeful |
|
| 243 |
+
| **Background** | Ivory/Pearl `#FEFEFE` β clean, calming |
|
| 244 |
+
| **Typography** | Playfair Display (headings) + DM Sans (body) |
|
| 245 |
+
| **Accessibility** | WCAG AA compliant, high contrast for tired eyes |
|
| 246 |
+
|
| 247 |
+
---
|
| 248 |
+
|
| 249 |
+
## π οΈ Tech Stack
|
| 250 |
+
|
| 251 |
+
### Core Technologies
|
| 252 |
+
|
| 253 |
+
| Component | Technology | Version | Purpose |
|
| 254 |
+
|-----------|------------|---------|---------|
|
| 255 |
+
| **Runtime** | Python | 3.10+ | Core programming language |
|
| 256 |
+
| **Web Framework** | Gradio | 6.0+ | Modern UI with messages format |
|
| 257 |
+
| **AI Provider** | OpenRouter | - | LLM API gateway |
|
| 258 |
+
| **AI Model** | Claude Sonnet 4 | Latest | Empathetic, intelligent responses |
|
| 259 |
+
| **Validation** | Pydantic | 2.11+ | Type-safe data models |
|
| 260 |
+
| **Configuration** | pydantic-settings | 2.7+ | Environment management |
|
| 261 |
+
| **Medical Standards** | HL7 FHIR R4 | - | Interoperable patient data |
|
| 262 |
+
|
| 263 |
+
### Document Processing
|
| 264 |
+
|
| 265 |
+
| Library | Purpose |
|
| 266 |
+
|---------|---------|
|
| 267 |
+
| **PyMuPDF (fitz)** | PDF text extraction |
|
| 268 |
+
| **python-docx** | Word document parsing |
|
| 269 |
+
| **pandas** | CSV/Excel data analysis |
|
| 270 |
+
| **openpyxl** | Excel XLSX support |
|
| 271 |
+
| **xlrd** | Legacy XLS support |
|
| 272 |
+
|
| 273 |
+
### Development Tools
|
| 274 |
+
|
| 275 |
+
| Tool | Purpose |
|
| 276 |
+
|------|---------|
|
| 277 |
+
| **pytest** | Testing framework |
|
| 278 |
+
| **pytest-asyncio** | Async test support |
|
| 279 |
+
| **black** | Code formatting |
|
| 280 |
+
| **ruff** | Fast Python linter |
|
| 281 |
+
| **mypy** | Static type checking |
|
| 282 |
+
| **loguru** | Beautiful logging |
|
| 283 |
+
|
| 284 |
+
### Dependencies Overview
|
| 285 |
+
|
| 286 |
+
```txt
|
| 287 |
+
# Core Framework
|
| 288 |
+
gradio>=6.0.0
|
| 289 |
+
openai>=1.54.0
|
| 290 |
+
pydantic>=2.11.0
|
| 291 |
+
pydantic-settings>=2.7.0
|
| 292 |
+
|
| 293 |
+
# Document Processing
|
| 294 |
+
PyMuPDF>=1.24.0
|
| 295 |
+
python-docx>=1.1.0
|
| 296 |
+
pandas>=2.2.0
|
| 297 |
+
|
| 298 |
+
# Development
|
| 299 |
+
pytest>=8.3.0
|
| 300 |
+
black>=24.10.0
|
| 301 |
+
ruff>=0.8.0
|
| 302 |
+
```
|
| 303 |
+
|
| 304 |
+
---
|
| 305 |
+
|
| 306 |
+
## ποΈ Architecture
|
| 307 |
+
|
| 308 |
+
### System Overview
|
| 309 |
+
|
| 310 |
+
```
|
| 311 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 312 |
+
β USER INTERFACE β
|
| 313 |
+
β (Gradio 6.0 Web App) β
|
| 314 |
+
βββββββββββββββ¬βββββββββββββββββββ¬βββββββββββββββββ¬ββββββββββββββββ€
|
| 315 |
+
β Chat UI β Medication UI β File Upload β Quick Actionsβ
|
| 316 |
+
ββββββββ¬βββββββ΄βββββββββ¬ββββββββββ΄ββββββββ¬βββββββββ΄ββββββββ¬ββββββββ
|
| 317 |
+
β β β β
|
| 318 |
+
βΌ βΌ βΌ βΌ
|
| 319 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 320 |
+
β APPLICATION LAYER β
|
| 321 |
+
β (app/main.py) β
|
| 322 |
+
βββββββββββββββ¬βββββββββββββββββββ¬βββββββββββββββββββββββββββββββββ€
|
| 323 |
+
β ChatHandler β MedicationReminderβ FileProcessor β
|
| 324 |
+
β (chat.py) β (reminders.py) β (main.py) β
|
| 325 |
+
ββββββββ¬βββββββ΄βββββββββ¬ββββββββββ΄βββββββββββββββββββββββββββββββββ
|
| 326 |
+
β β
|
| 327 |
+
βΌ βΌ
|
| 328 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 329 |
+
β CORE SERVICES β
|
| 330 |
+
βββββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββββ€
|
| 331 |
+
β LLMAgent β Data Models β
|
| 332 |
+
β (agents.py) β (schemas.py) β
|
| 333 |
+
β β β
|
| 334 |
+
β β’ Async OpenAI SDK β β’ Medication / MedicationLog β
|
| 335 |
+
β β’ Streaming support β β’ ConversationSession β
|
| 336 |
+
β β’ Error handling β β’ MedicationState β
|
| 337 |
+
βββββββββββββ¬ββββββββββββ΄ββββββββββββββββββββββββββββββββββββββββββ
|
| 338 |
+
β
|
| 339 |
+
βΌ
|
| 340 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 341 |
+
β EXTERNAL SERVICES β
|
| 342 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
|
| 343 |
+
β OpenRouter API β
|
| 344 |
+
β (anthropic/claude-sonnet-4) β
|
| 345 |
+
β β
|
| 346 |
+
β ββββββββββββββββββββββββββββββββββββ β
|
| 347 |
+
β β HTTP/HTTPS + Streaming SSE β β
|
| 348 |
+
β β β’ Max 4096 tokens β β
|
| 349 |
+
β β β’ Temperature 0.7 β β
|
| 350 |
+
β β β’ Async with httpx β β
|
| 351 |
+
β ββββββββββββββββββββββββββββββββββββ β
|
| 352 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 353 |
+
```
|
| 354 |
+
|
| 355 |
+
### Component Details
|
| 356 |
+
|
| 357 |
+
#### 1. Main Interface (`app/main.py`)
|
| 358 |
+
- Creates Gradio 6 Blocks interface
|
| 359 |
+
- Handles file upload and processing
|
| 360 |
+
- Coordinates chat and medication features
|
| 361 |
+
- Injects custom CSS styling
|
| 362 |
+
|
| 363 |
+
#### 2. Chat Handler (`app/chat.py`)
|
| 364 |
+
- Manages conversation sessions
|
| 365 |
+
- Converts between Gradio 6 messages format and OpenAI API
|
| 366 |
+
- Handles streaming and non-streaming responses
|
| 367 |
+
- **Detects worsening factors** in user messages
|
| 368 |
+
- **Enhances system prompts** with medical context
|
| 369 |
+
- **Caches medical context** for performance (60s TTL)
|
| 370 |
+
|
| 371 |
+
#### 3. LLM Agent (`app/llm_agent.py`)
|
| 372 |
+
- Async OpenAI SDK client for OpenRouter
|
| 373 |
+
- Loads system prompt from file
|
| 374 |
+
- Implements retry logic and error handling
|
| 375 |
+
- Supports both streaming and batch responses
|
| 376 |
+
|
| 377 |
+
#### 4. Medical Intelligence Services (`app/services/`)
|
| 378 |
+
|
| 379 |
+
| Service | Purpose |
|
| 380 |
+
|---------|---------|
|
| 381 |
+
| **AdaptiveReasoningRouter** | Routes queries to parallel/sequential/deep modes based on complexity |
|
| 382 |
+
| **MedicalKnowledgeService** | 8 query methods for features, guidelines, differential diagnosis |
|
| 383 |
+
| **EUGuidelinesValidator** | Validates against EULAR 2016, German S3, UK NICE guidelines |
|
| 384 |
+
|
| 385 |
+
#### 5. Multi-Agent System (`app/agents/`)
|
| 386 |
+
|
| 387 |
+
| Agent | Role |
|
| 388 |
+
|-------|------|
|
| 389 |
+
| **FibroAgentCouncil** | Orchestrates specialized agents with consensus synthesis |
|
| 390 |
+
| **SymptomAnalyzer** | Analyzes symptom patterns and severity |
|
| 391 |
+
| **TherapyExpert** | Recommends evidence-based treatments |
|
| 392 |
+
| **LifestyleCoach** | Provides pacing and lifestyle strategies |
|
| 393 |
+
| **RiskAssessor** | Evaluates safety and recommends escalation |
|
| 394 |
+
|
| 395 |
+
**Exploration Strategies:**
|
| 396 |
+
- **Parallel Consensus** β All agents run simultaneously for routine queries
|
| 397 |
+
- **Deep Sequential with Backtracking** β DFS-style hypothesis exploration for complex cases
|
| 398 |
+
|
| 399 |
+
#### 6. FHIR Patient Profile (`app/schemas/patient.py`)
|
| 400 |
+
- HL7 FHIR R4 compliant patient resource
|
| 401 |
+
- **WPI** (Widespread Pain Index) 0-19
|
| 402 |
+
- **SSS** (Symptom Severity Score) 0-12
|
| 403 |
+
- **ACR 2016 criteria** automatic calculation
|
| 404 |
+
- **PHI masking** for privacy protection
|
| 405 |
+
|
| 406 |
+
#### 7. Medication Reminder (`app/reminders.py`)
|
| 407 |
+
- In-memory medication state management
|
| 408 |
+
- LLM command parsing (`[MEDICATION_CMD: ...]`)
|
| 409 |
+
- Adherence tracking and statistics
|
| 410 |
+
- Pending reminder detection
|
| 411 |
+
- **Missed dose detection** (after 4 AM daily check)
|
| 412 |
+
- Actions: mark taken late, register missed, dismiss
|
| 413 |
+
|
| 414 |
+
#### 8. Appointment Reminder (`app/appointments.py`)
|
| 415 |
+
- Doctor appointment scheduling and tracking
|
| 416 |
+
- Specialty-based categorization
|
| 417 |
+
- Day-before reminder system
|
| 418 |
+
- Status indicators (Today, Soon, Upcoming, Past)
|
| 419 |
+
- LLM command parsing (`[APPOINTMENT_CMD: ...]`)
|
| 420 |
+
|
| 421 |
+
#### 9. Internationalization (`app/i18n.py`)
|
| 422 |
+
- 21 supported languages with JSON translation files
|
| 423 |
+
- Dynamic language switching at runtime
|
| 424 |
+
- Nested key access with dot notation
|
| 425 |
+
- Automatic fallback to English
|
| 426 |
+
- `UIStrings` class for type-safe UI text access
|
| 427 |
+
|
| 428 |
+
#### 10. Configuration (`app/config.py`)
|
| 429 |
+
- Pydantic Settings with validation
|
| 430 |
+
- Environment variable loading
|
| 431 |
+
- Type-safe configuration access
|
| 432 |
+
- Default language setting
|
| 433 |
+
|
| 434 |
+
#### 11. Data Models (`models/schemas.py`)
|
| 435 |
+
- Pydantic 2.11 models
|
| 436 |
+
- Gradio 6 messages format support
|
| 437 |
+
- Medication and logging schemas
|
| 438 |
+
|
| 439 |
+
### Directory Structure
|
| 440 |
+
|
| 441 |
+
```
|
| 442 |
+
hellofibro/
|
| 443 |
+
βββ app/ # Application code
|
| 444 |
+
β βββ __init__.py
|
| 445 |
+
β βββ main.py # Gradio interface + file processing
|
| 446 |
+
β βββ config.py # Pydantic settings
|
| 447 |
+
β βββ llm_agent.py # LLM agent (OpenRouter)
|
| 448 |
+
β βββ chat.py # Chat session management + medical context
|
| 449 |
+
β βββ prompts.py # LLM prompts and file hints
|
| 450 |
+
β βββ i18n.py # Internationalization service (21 languages)
|
| 451 |
+
β βββ security.py # Input sanitization + HIPAA audit
|
| 452 |
+
β βββ reminders.py # Medication system
|
| 453 |
+
β βββ appointments.py # Appointment management
|
| 454 |
+
β β
|
| 455 |
+
β βββ agents/ # π Multi-agent system
|
| 456 |
+
β β βββ __init__.py
|
| 457 |
+
β β βββ council.py # FibroAgentCouncil with backtracking
|
| 458 |
+
β β
|
| 459 |
+
β βββ schemas/ # π Medical data schemas
|
| 460 |
+
β β βββ __init__.py
|
| 461 |
+
β β βββ patient.py # FHIR R4 patient profile + ACR 2016
|
| 462 |
+
β β
|
| 463 |
+
β βββ services/ # π Medical intelligence services
|
| 464 |
+
β βββ __init__.py
|
| 465 |
+
β βββ reasoning_router.py # Adaptive chain-of-thought scaling
|
| 466 |
+
β βββ medical_knowledge.py # Knowledge base queries
|
| 467 |
+
β βββ eu_guidelines_validator.py # EULAR/S3/NICE compliance
|
| 468 |
+
β
|
| 469 |
+
βββ models/ # Data models
|
| 470 |
+
β βββ __init__.py
|
| 471 |
+
β βββ schemas.py # Pydantic schemas
|
| 472 |
+
β
|
| 473 |
+
βββ data/ # Static data
|
| 474 |
+
β βββ prompts/
|
| 475 |
+
β β βββ system_prompt.txt # AI personality definition
|
| 476 |
+
β βββ translations/ # UI translations (21 languages)
|
| 477 |
+
β β βββ en-US.json # English (US)
|
| 478 |
+
β β βββ pl.json # Polish
|
| 479 |
+
β β βββ de.json # German
|
| 480 |
+
β β βββ ... # 18 more languages
|
| 481 |
+
β βββ features.json # 15 worsening factors
|
| 482 |
+
β βββ metrics.json # 8 evaluation metrics
|
| 483 |
+
β βββ guidelines.json # EU clinical guidelines
|
| 484 |
+
β βββ reasoning_config.json # Reasoning mode configuration
|
| 485 |
+
β
|
| 486 |
+
βββ static/ # Web assets
|
| 487 |
+
β βββ logo.png # App logo
|
| 488 |
+
β βββ custom.css # Premium styling (1100+ lines)
|
| 489 |
+
β
|
| 490 |
+
βββ resources/ # Design resources
|
| 491 |
+
β βββ hellofibro_logo.png # Original logo
|
| 492 |
+
β βββ style.css # Reference styles
|
| 493 |
+
β βββ hellofibro-gradio6-modern.md
|
| 494 |
+
β
|
| 495 |
+
βββ tests/ # Test suite
|
| 496 |
+
β βββ __init__.py
|
| 497 |
+
β βββ conftest.py # Pytest fixtures (incl. medical)
|
| 498 |
+
β βββ test_chat.py # Chat tests
|
| 499 |
+
β βββ test_agents.py # Agent tests
|
| 500 |
+
β βββ test_reminders.py # Medication tests
|
| 501 |
+
β βββ test_missed_doses.py # Missed dose notification tests
|
| 502 |
+
β βββ test_config.py # Config tests
|
| 503 |
+
β βββ test_e2e.py # End-to-end tests
|
| 504 |
+
β βββ test_medical_layer.py # π Medical services unit tests
|
| 505 |
+
β βββ test_medical_integration.py # π Medical integration tests
|
| 506 |
+
β
|
| 507 |
+
βββ .env # Environment config (create this)
|
| 508 |
+
βββ .env.example # Example environment file
|
| 509 |
+
βββ requirements.txt # Python dependencies
|
| 510 |
+
βββ Makefile # Development commands
|
| 511 |
+
βββ Dockerfile # Container definition
|
| 512 |
+
βββ docker-compose.yml # Container orchestration
|
| 513 |
+
βββ pyproject.toml # Project metadata
|
| 514 |
+
βββ BRANDING_GUIDE.md # Design system documentation
|
| 515 |
+
βββ IMPLEMENTATION_PLAN.md # Development roadmap
|
| 516 |
+
βββ README.md # This file
|
| 517 |
+
```
|
| 518 |
+
|
| 519 |
+
---
|
| 520 |
+
|
| 521 |
+
## π Workflows
|
| 522 |
+
|
| 523 |
+
### Chat Conversation Flow
|
| 524 |
+
|
| 525 |
+
```
|
| 526 |
+
βββββββββββββββ βββββββββββββββ βββββββββββββββ
|
| 527 |
+
β User β β Gradio UI β β ChatHandler β
|
| 528 |
+
β Input βββββββΆβ (main.py) βββββββΆβ (chat.py) β
|
| 529 |
+
βββββββββββββββ βββββββββββββββ ββββββββ¬βββββββ
|
| 530 |
+
β
|
| 531 |
+
βΌ
|
| 532 |
+
βββββββββββββββ βββββββββββββββ βββββββββββββββ
|
| 533 |
+
β Streaming ββββββββ LLMAgent ββββββββ Session β
|
| 534 |
+
β Response β β (agents.py) β β History β
|
| 535 |
+
βββββββββββββββ ββββββββ¬βββββββ βββββββββββββββ
|
| 536 |
+
β
|
| 537 |
+
βΌ
|
| 538 |
+
βββββββββββββββββ
|
| 539 |
+
β OpenRouter β
|
| 540 |
+
β Claude API β
|
| 541 |
+
βββββββββββββββββ
|
| 542 |
+
```
|
| 543 |
+
|
| 544 |
+
**Step-by-step:**
|
| 545 |
+
|
| 546 |
+
1. **User Input** β User types message + optional file upload
|
| 547 |
+
2. **File Processing** β Extract text from PDF/DOCX/CSV/images
|
| 548 |
+
3. **Context Building** β Add medication/appointment context + file hints
|
| 549 |
+
4. **Session Management** β Retrieve/create conversation session
|
| 550 |
+
5. **LLM Request** β Send to Claude via OpenRouter with streaming
|
| 551 |
+
6. **Response Processing** β Extract medication commands, clean response
|
| 552 |
+
7. **UI Update** β Stream response to chat interface
|
| 553 |
+
|
| 554 |
+
### Medication Management Flow
|
| 555 |
+
|
| 556 |
+
```
|
| 557 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 558 |
+
β USER ACTIONS β
|
| 559 |
+
ββββββββββββββββ¬βββββββββββββββ¬ββββββββββββββββ¬ββββββββββββββββ€
|
| 560 |
+
β "Dodaj lek β Click "Add β Click "Take" β "WziΔ
Εem β
|
| 561 |
+
β X 100mg" β Medication" β Button β pregabalinΔ" β
|
| 562 |
+
ββββββββ¬ββββββββ΄βββββββ¬ββββββββ΄ββββββββ¬ββββββββ΄ββββββββ¬ββββββββ
|
| 563 |
+
β β β β
|
| 564 |
+
βΌ βΌ βΌ βΌ
|
| 565 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 566 |
+
β PROCESSING LAYER β
|
| 567 |
+
βββββββββββββββββββββββ¬ββββββββββββββββββββββββββββββββββββββββ€
|
| 568 |
+
β LLM generates: β Direct UI Handler: β
|
| 569 |
+
β [MEDICATION_CMD: β add_medication_ui() β
|
| 570 |
+
β ADD: X|100mg|...] β mark_taken_ui() β
|
| 571 |
+
ββββββββββββ¬βββββββββββ΄ββββββββββββββββ¬ββββββββββββββββββββββββ
|
| 572 |
+
β β
|
| 573 |
+
βΌ βΌ
|
| 574 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 575 |
+
β MedicationReminder (reminders.py) β
|
| 576 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
|
| 577 |
+
β β’ add_medication() β’ mark_taken() β
|
| 578 |
+
β β’ remove_medication() β’ get_medications_for_display() β
|
| 579 |
+
β β’ get_today_status() β’ process_llm_medication_command() β
|
| 580 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 581 |
+
β
|
| 582 |
+
βΌ
|
| 583 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 584 |
+
β MedicationState β
|
| 585 |
+
β (In-memory storage with Pydantic models) β
|
| 586 |
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
| 587 |
+
```
|
| 588 |
+
|
| 589 |
+
**LLM Command Format:**
|
| 590 |
+
|
| 591 |
+
```python
|
| 592 |
+
# Adding medication via chat
|
| 593 |
+
[MEDICATION_CMD: ADD: Pregabalina|150mg|21:00|wieczorem|na bΓ³l neuropatyczny]
|
| 594 |
+
|
| 595 |
+
# Removing medication
|
| 596 |
+
[MEDICATION_CMD: REMOVE: Pregabalina]
|
| 597 |
+
|
| 598 |
+
# Marking as taken
|
| 599 |
+
[MEDICATION_CMD: TAKEN: Pregabalina]
|
| 600 |
+
|
| 601 |
+
# Listing all medications
|
| 602 |
+
[MEDICATION_CMD: LIST:]
|
| 603 |
+
```
|
| 604 |
+
|
| 605 |
+
### Appointment Management Flow
|
| 606 |
+
|
| 607 |
+
```
|
| 608 |
+
+---------------+ +------------------+ +-------------------+
|
| 609 |
+
| USER ACTIONS | | PROCESSING LAYER | | AppointmentReminder|
|
| 610 |
+
+---------------+ +------------------+ +-------------------+
|
| 611 |
+
| | |
|
| 612 |
+
v v v
|
| 613 |
+
"Add visit" LLM generates: add_appointment()
|
| 614 |
+
Click Form [APPOINTMENT_CMD: ADD: ...] get_appointments()
|
| 615 |
+
Click Card OR remove_appointment()
|
| 616 |
+
| Direct UI Handler |
|
| 617 |
+
+--------->----------------------->---------------+
|
| 618 |
+
|
|
| 619 |
+
v
|
| 620 |
+
+-------------------+
|
| 621 |
+
| AppointmentState |
|
| 622 |
+
| (In-memory) |
|
| 623 |
+
+-------------------+
|
| 624 |
+
```
|
| 625 |
+
|
| 626 |
+
**LLM Command Format:**
|
| 627 |
+
|
| 628 |
+
```python
|
| 629 |
+
# Adding appointment via chat
|
| 630 |
+
[APPOINTMENT_CMD: ADD: Dr. Smith|Rheumatologist|2025-01-15|10:00|ABC Clinic|bring test results]
|
| 631 |
+
|
| 632 |
+
# Removing appointment
|
| 633 |
+
[APPOINTMENT_CMD: REMOVE: Dr. Smith]
|
| 634 |
+
|
| 635 |
+
# Listing all appointments
|
| 636 |
+
[APPOINTMENT_CMD: LIST:]
|
| 637 |
+
```
|
| 638 |
+
|
| 639 |
+
### File Processing Flow
|
| 640 |
+
|
| 641 |
+
```
|
| 642 |
+
βββββββββββββββ ββββββββββββββββββββ βββββββββββββββ
|
| 643 |
+
β File Upload βββββββΆβ process_uploaded βββββββΆβ Type Check β
|
| 644 |
+
β (User) β β _file() β β & Validate β
|
| 645 |
+
βββββββββββββββ ββββββββββββββββββββ ββββββββ¬βββββββ
|
| 646 |
+
β
|
| 647 |
+
βββββββββββββββββββββββββββββββββββΌββββββββββββββββββ
|
| 648 |
+
β β β
|
| 649 |
+
βΌ βΌ βΌ
|
| 650 |
+
βββββββββββββββ βββββββββββββββ βββββββββββββββ
|
| 651 |
+
β PDF (fitz) β β DOCX/DOC β β CSV/XLSX β
|
| 652 |
+
β extract_pdf β β extract_docxβ β pandas read β
|
| 653 |
+
β _text() β β _text() β β β
|
| 654 |
+
ββββββββ¬βββββββ ββββββββ¬βββββββ ββββββββ¬βββββββ
|
| 655 |
+
β β β
|
| 656 |
+
βββββββββββββββββ¬ββββββββββββββββ΄βββββββββββββββββββ
|
| 657 |
+
β
|
| 658 |
+
βΌ
|
| 659 |
+
βββββββββββββββββββ
|
| 660 |
+
β Content + Hint β
|
| 661 |
+
β for LLM Context β
|
| 662 |
+
ββββββββββ¬βββββββββ
|
| 663 |
+
β
|
| 664 |
+
βΌ
|
| 665 |
+
βββββββββββββββββββ
|
| 666 |
+
β Enhanced Chat β
|
| 667 |
+
β Message β
|
| 668 |
+
βββββββββββββββββββ
|
| 669 |
+
```
|
| 670 |
+
|
| 671 |
+
**Supported File Processing:**
|
| 672 |
+
|
| 673 |
+
| Type | Library | Max Size | Features |
|
| 674 |
+
|------|---------|----------|----------|
|
| 675 |
+
| PDF | PyMuPDF | 15MB | Multi-page, page markers |
|
| 676 |
+
| DOCX | python-docx | 15MB | Paragraphs + tables |
|
| 677 |
+
| XLSX/XLS | pandas + openpyxl | 15MB | Multi-sheet, statistics |
|
| 678 |
+
| CSV | pandas | 15MB | Headers, stats preview |
|
| 679 |
+
| TXT/MD/JSON | Built-in | 50KB | UTF-8 with fallback |
|
| 680 |
+
| Images | Base64 | 15MB | Vision model support |
|
| 681 |
+
|
| 682 |
+
---
|
| 683 |
+
|
| 684 |
+
## π Quick Start
|
| 685 |
+
|
| 686 |
+
### Prerequisites
|
| 687 |
+
|
| 688 |
+
- **Python 3.10+** installed
|
| 689 |
+
- **OpenRouter API key** ([Get one here](https://openrouter.ai))
|
| 690 |
+
|
| 691 |
+
### Installation
|
| 692 |
+
|
| 693 |
+
```bash
|
| 694 |
+
# 1. Clone the repository
|
| 695 |
+
git clone https://github.com/hellofibro/hellofibro.git
|
| 696 |
+
cd hellofibro
|
| 697 |
+
|
| 698 |
+
# 2. Create virtual environment
|
| 699 |
+
python -m venv venv
|
| 700 |
+
|
| 701 |
+
# Windows
|
| 702 |
+
.\venv\Scripts\activate
|
| 703 |
+
|
| 704 |
+
# macOS/Linux
|
| 705 |
+
source venv/bin/activate
|
| 706 |
+
|
| 707 |
+
# 3. Install dependencies
|
| 708 |
+
pip install -r requirements.txt
|
| 709 |
+
|
| 710 |
+
# 4. Create environment file
|
| 711 |
+
cp .env.example .env
|
| 712 |
+
# Edit .env and add your OPENROUTER_API_KEY
|
| 713 |
+
|
| 714 |
+
# 5. Run the application
|
| 715 |
+
python -m app.main
|
| 716 |
+
```
|
| 717 |
+
|
| 718 |
+
### Using Docker
|
| 719 |
+
|
| 720 |
+
```bash
|
| 721 |
+
# Build and run with Docker Compose
|
| 722 |
+
docker-compose up --build -d
|
| 723 |
+
|
| 724 |
+
# View logs
|
| 725 |
+
docker-compose logs -f
|
| 726 |
+
|
| 727 |
+
# Stop the container
|
| 728 |
+
docker-compose down
|
| 729 |
+
```
|
| 730 |
+
|
| 731 |
+
**Container Status:**
|
| 732 |
+
```
|
| 733 |
+
NAME IMAGE STATUS PORTS
|
| 734 |
+
hellofibro hellofibro-hellofibro Up (running) 0.0.0.0:7860->7860/tcp
|
| 735 |
+
```
|
| 736 |
+
|
| 737 |
+
**With API Key (Production):**
|
| 738 |
+
|
| 739 |
+
```bash
|
| 740 |
+
# Windows PowerShell
|
| 741 |
+
$env:OPENROUTER_API_KEY="sk-or-v1-your-key-here"
|
| 742 |
+
docker-compose up -d
|
| 743 |
+
|
| 744 |
+
# Linux/macOS
|
| 745 |
+
export OPENROUTER_API_KEY="sk-or-v1-your-key-here"
|
| 746 |
+
docker-compose up -d
|
| 747 |
+
|
| 748 |
+
# Or create .env file first
|
| 749 |
+
echo "OPENROUTER_API_KEY=sk-or-v1-your-key-here" > .env
|
| 750 |
+
docker-compose up -d
|
| 751 |
+
```
|
| 752 |
+
|
| 753 |
+
**Demo Mode (No API Key):**
|
| 754 |
+
|
| 755 |
+
Without an API key, the app runs in demo mode with pre-defined responses:
|
| 756 |
+
|
| 757 |
+
```bash
|
| 758 |
+
docker-compose up -d
|
| 759 |
+
# Logs will show: "Running in DEMO MODE - API calls disabled"
|
| 760 |
+
```
|
| 761 |
+
|
| 762 |
+
**Manual Docker Build:**
|
| 763 |
+
|
| 764 |
+
```bash
|
| 765 |
+
# Build image
|
| 766 |
+
docker build -t hellofibro .
|
| 767 |
+
|
| 768 |
+
# Run with environment variable
|
| 769 |
+
docker run -p 7860:7860 -e OPENROUTER_API_KEY=sk-or-v1-xxx hellofibro
|
| 770 |
+
|
| 771 |
+
# Or with .env file
|
| 772 |
+
docker run -p 7860:7860 --env-file .env hellofibro
|
| 773 |
+
```
|
| 774 |
+
|
| 775 |
+
**Docker Compose Configuration:**
|
| 776 |
+
|
| 777 |
+
The `docker-compose.yml` includes:
|
| 778 |
+
- Health checks (every 30s)
|
| 779 |
+
- Resource limits (2 CPU, 2GB RAM)
|
| 780 |
+
- Automatic restart policy
|
| 781 |
+
- Environment variable passthrough
|
| 782 |
+
|
| 783 |
+
### Using Make (Recommended)
|
| 784 |
+
|
| 785 |
+
```bash
|
| 786 |
+
make setup # Create venv + install dependencies
|
| 787 |
+
make run # Start the application
|
| 788 |
+
make test # Run all tests
|
| 789 |
+
make lint # Check code quality
|
| 790 |
+
make format # Format code with black
|
| 791 |
+
make clean # Remove cache files
|
| 792 |
+
```
|
| 793 |
+
|
| 794 |
+
### Access the App
|
| 795 |
+
|
| 796 |
+
```
|
| 797 |
+
π Open http://localhost:7860 in your browser
|
| 798 |
+
```
|
| 799 |
+
|
| 800 |
+
---
|
| 801 |
+
|
| 802 |
+
## βοΈ Configuration
|
| 803 |
+
|
| 804 |
+
Create a `.env` file in the project root:
|
| 805 |
+
|
| 806 |
+
```env
|
| 807 |
+
# Required - Your OpenRouter API key
|
| 808 |
+
OPENROUTER_API_KEY=sk-or-v1-your-api-key-here
|
| 809 |
+
|
| 810 |
+
# Optional - Model selection (defaults shown)
|
| 811 |
+
OPENROUTER_MODEL=anthropic/claude-sonnet-4
|
| 812 |
+
OPENROUTER_BASE_URL=https://openrouter.ai/api/v1
|
| 813 |
+
|
| 814 |
+
# Optional - Model parameters
|
| 815 |
+
MODEL_MAX_TOKENS=4096
|
| 816 |
+
MODEL_TEMPERATURE=0.7
|
| 817 |
+
|
| 818 |
+
# Optional - Application settings
|
| 819 |
+
APP_TITLE=HelloFibro
|
| 820 |
+
APP_HOST=0.0.0.0
|
| 821 |
+
APP_PORT=7860
|
| 822 |
+
|
| 823 |
+
# Optional - Feature flags
|
| 824 |
+
DEBUG_MODE=false # Set to true to test missed dose notifications anytime
|
| 825 |
+
STREAM_RESPONSES=true
|
| 826 |
+
LOG_LEVEL=INFO
|
| 827 |
+
|
| 828 |
+
# Optional - Internationalization
|
| 829 |
+
DEFAULT_LANGUAGE=pl # Default UI language (pl, en-US, de, es, fr, etc.)
|
| 830 |
+
```
|
| 831 |
+
|
| 832 |
+
### Supported Languages
|
| 833 |
+
|
| 834 |
+
| Code | Language | Native Name |
|
| 835 |
+
|------|----------|-------------|
|
| 836 |
+
| `en-US` | English (US) | English (US) |
|
| 837 |
+
| `en-GB` | English (UK) | English (UK) |
|
| 838 |
+
| `pl` | Polish | Polski |
|
| 839 |
+
| `de` | German | Deutsch |
|
| 840 |
+
| `es` | Spanish | Espanol |
|
| 841 |
+
| `fr` | French | Francais |
|
| 842 |
+
| `it` | Italian | Italiano |
|
| 843 |
+
| `nl` | Dutch | Nederlands |
|
| 844 |
+
| `pt` | Portuguese | Portugues |
|
| 845 |
+
| `sv` | Swedish | Svenska |
|
| 846 |
+
| `no` | Norwegian | Norsk |
|
| 847 |
+
| `da` | Danish | Dansk |
|
| 848 |
+
| `ja` | Japanese | Nihongo |
|
| 849 |
+
| `ko` | Korean | Hangugeo |
|
| 850 |
+
| `zh` | Chinese | Zhongwen |
|
| 851 |
+
| `ar` | Arabic | Al-Arabiyyah |
|
| 852 |
+
| `he` | Hebrew | Ivrit |
|
| 853 |
+
| `hi` | Hindi | Hindi |
|
| 854 |
+
| `th` | Thai | Phasa Thai |
|
| 855 |
+
| `tr` | Turkish | Turkce |
|
| 856 |
+
| `id` | Indonesian | Bahasa Indonesia |
|
| 857 |
+
|
| 858 |
+
### Supported Models
|
| 859 |
+
|
| 860 |
+
Any OpenRouter-compatible model works. Recommended options:
|
| 861 |
+
|
| 862 |
+
| Model | ID | Best For |
|
| 863 |
+
|-------|-----|----------|
|
| 864 |
+
| **Claude Sonnet 4** | `anthropic/claude-sonnet-4` | Best quality (default) |
|
| 865 |
+
| **Claude 3.5 Sonnet** | `anthropic/claude-3.5-sonnet` | Fast, excellent |
|
| 866 |
+
| **GPT-4o** | `openai/gpt-4o` | Alternative |
|
| 867 |
+
| **Claude 3 Haiku** | `anthropic/claude-3-haiku` | Budget-friendly |
|
| 868 |
+
|
| 869 |
+
---
|
| 870 |
+
|
| 871 |
+
## π§ͺ Testing
|
| 872 |
+
|
| 873 |
+
```bash
|
| 874 |
+
# Run all tests
|
| 875 |
+
pytest tests/ -v
|
| 876 |
+
|
| 877 |
+
# Run with coverage
|
| 878 |
+
pytest tests/ --cov=app --cov=models
|
| 879 |
+
|
| 880 |
+
# Run specific test file
|
| 881 |
+
pytest tests/test_chat.py -v
|
| 882 |
+
|
| 883 |
+
# Run async tests only
|
| 884 |
+
pytest tests/ -v -k "async"
|
| 885 |
+
```
|
| 886 |
+
|
| 887 |
+
### Test Categories
|
| 888 |
+
|
| 889 |
+
| File | Tests |
|
| 890 |
+
|------|-------|
|
| 891 |
+
| `test_config.py` | Settings validation, API key format |
|
| 892 |
+
| `test_agents.py` | LLM agent, streaming, error handling |
|
| 893 |
+
| `test_chat.py` | Session management, message processing |
|
| 894 |
+
| `test_reminders.py` | Medication CRUD, logging, commands |
|
| 895 |
+
| `test_missed_doses.py` | Missed dose detection, actions |
|
| 896 |
+
| `test_language_selection.py` | i18n service, language switching |
|
| 897 |
+
| `test_e2e.py` | End-to-end integration tests |
|
| 898 |
+
| `test_medical_layer.py` | Medical services unit tests |
|
| 899 |
+
| `test_medical_integration.py` | End-to-end medical integration |
|
| 900 |
+
|
| 901 |
+
### Medical Intelligence Tests
|
| 902 |
+
|
| 903 |
+
```bash
|
| 904 |
+
# Run medical layer tests specifically
|
| 905 |
+
pytest tests/test_medical_layer.py -v
|
| 906 |
+
pytest tests/test_medical_integration.py -v
|
| 907 |
+
|
| 908 |
+
# Run all tests including medical
|
| 909 |
+
pytest tests/ -v --tb=short
|
| 910 |
+
```
|
| 911 |
+
|
| 912 |
+
**Tested Components:**
|
| 913 |
+
- MedicalKnowledgeService queries (features, guidelines, differential)
|
| 914 |
+
- EUGuidelinesValidator (therapy validation, contraindications)
|
| 915 |
+
- AdaptiveReasoningRouter (complexity assessment, mode routing)
|
| 916 |
+
- FibroPatientProfile (ACR 2016, PHI masking, FHIR export)
|
| 917 |
+
- ChatHandler medical context integration
|
| 918 |
+
- FibroAgentCouncil parallel/deep modes
|
| 919 |
+
|
| 920 |
+
---
|
| 921 |
+
|
| 922 |
+
## π Security & Privacy
|
| 923 |
+
|
| 924 |
+
HelloFibro is designed with privacy as a core principle:
|
| 925 |
+
|
| 926 |
+
| Aspect | Implementation |
|
| 927 |
+
|--------|----------------|
|
| 928 |
+
| **Data Storage** | Session-only, in-memory (no persistence) |
|
| 929 |
+
| **API Keys** | Stored in `.env`, never logged or transmitted |
|
| 930 |
+
| **User Data** | Not stored, not tracked, not shared |
|
| 931 |
+
| **Conversations** | Cleared on session end |
|
| 932 |
+
| **Medications** | In-memory only (MVP) |
|
| 933 |
+
| **File Uploads** | Processed in memory, not stored |
|
| 934 |
+
| **PHI Protection** | π FHIR patient profiles support PHI masking |
|
| 935 |
+
| **Medical Data** | π No patient data persisted, session-only |
|
| 936 |
+
|
| 937 |
+
### Important Notes
|
| 938 |
+
|
| 939 |
+
- β
HTTPS recommended for production
|
| 940 |
+
- β
API key validation at startup
|
| 941 |
+
- β
No PII collection or storage
|
| 942 |
+
- β οΈ Future versions may add optional persistence with encryption
|
| 943 |
+
|
| 944 |
+
---
|
| 945 |
+
|
| 946 |
+
## β οΈ Medical Disclaimer
|
| 947 |
+
|
| 948 |
+
> **HelloFibro is NOT a substitute for professional medical advice.**
|
| 949 |
+
|
| 950 |
+
This AI assistant provides general support and information only:
|
| 951 |
+
|
| 952 |
+
| β HelloFibro Does NOT | β
HelloFibro Does |
|
| 953 |
+
|------------------------|-------------------|
|
| 954 |
+
| Diagnose conditions | Provide emotional support |
|
| 955 |
+
| Prescribe medications | Track prescribed medications |
|
| 956 |
+
| Replace healthcare providers | Help prepare for doctor visits |
|
| 957 |
+
| Provide emergency advice | Offer coping strategies |
|
| 958 |
+
| Make treatment decisions | Share general fibromyalgia info |
|
| 959 |
+
| Provide dosage advice | Reference EULAR/S3/NICE guidelines |
|
| 960 |
+
|
| 961 |
+
### Clinical Guidelines Compliance
|
| 962 |
+
|
| 963 |
+
HelloFibro references established clinical guidelines for informational purposes:
|
| 964 |
+
|
| 965 |
+
| Guideline | Year | Scope |
|
| 966 |
+
|-----------|------|-------|
|
| 967 |
+
| **EULAR 2016** | 2016 | European League Against Rheumatism |
|
| 968 |
+
| **German S3** | 2017 | German Association of Scientific Medical Societies |
|
| 969 |
+
| **UK NICE** | 2021 | UK National Institute for Health and Care Excellence |
|
| 970 |
+
| **ACR 2016** | 2016 | American College of Rheumatology diagnostic criteria |
|
| 971 |
+
|
| 972 |
+
**Always consult qualified healthcare professionals for medical decisions.**
|
| 973 |
+
|
| 974 |
+
---
|
| 975 |
+
|
| 976 |
+
## π€ Contributing
|
| 977 |
+
|
| 978 |
+
Contributions are welcome! Please follow these guidelines:
|
| 979 |
+
|
| 980 |
+
### Development Setup
|
| 981 |
+
|
| 982 |
+
```bash
|
| 983 |
+
# 1. Fork and clone
|
| 984 |
+
git clone https://github.com/YOUR_USERNAME/hellofibro.git
|
| 985 |
+
cd hellofibro
|
| 986 |
+
|
| 987 |
+
# 2. Create branch
|
| 988 |
+
git checkout -b feature/your-feature
|
| 989 |
+
|
| 990 |
+
# 3. Install dev dependencies
|
| 991 |
+
pip install -r requirements.txt
|
| 992 |
+
|
| 993 |
+
# 4. Make changes and test
|
| 994 |
+
make test
|
| 995 |
+
make lint
|
| 996 |
+
|
| 997 |
+
# 5. Format code
|
| 998 |
+
make format
|
| 999 |
+
|
| 1000 |
+
# 6. Commit and push
|
| 1001 |
+
git commit -m "feat: add amazing feature"
|
| 1002 |
+
git push origin feature/your-feature
|
| 1003 |
+
|
| 1004 |
+
# 7. Open Pull Request
|
| 1005 |
+
```
|
| 1006 |
+
|
| 1007 |
+
### Code Style
|
| 1008 |
+
|
| 1009 |
+
- **Formatting**: Black (line length 88)
|
| 1010 |
+
- **Linting**: Ruff
|
| 1011 |
+
- **Type Hints**: Required for all functions
|
| 1012 |
+
- **Docstrings**: Required for public APIs
|
| 1013 |
+
|
| 1014 |
+
### Commit Messages
|
| 1015 |
+
|
| 1016 |
+
Follow [Conventional Commits](https://www.conventionalcommits.org/):
|
| 1017 |
+
|
| 1018 |
+
```
|
| 1019 |
+
feat: add new medication reminder feature
|
| 1020 |
+
fix: resolve chat history persistence issue
|
| 1021 |
+
docs: update README with architecture diagram
|
| 1022 |
+
style: format code with black
|
| 1023 |
+
refactor: extract file processing to separate module
|
| 1024 |
+
test: add tests for medication commands
|
| 1025 |
+
```
|
| 1026 |
+
|
| 1027 |
+
---
|
| 1028 |
+
|
| 1029 |
+
## π License
|
| 1030 |
+
|
| 1031 |
+
This project is licensed under the **MIT License** - see the [LICENSE](LICENSE) file for details.
|
| 1032 |
+
|
| 1033 |
+
---
|
| 1034 |
+
|
| 1035 |
+
## π Acknowledgments
|
| 1036 |
+
|
| 1037 |
+
- Built with love for the fibromyalgia community π
|
| 1038 |
+
- AI powered by [Anthropic Claude](https://anthropic.com) via [OpenRouter](https://openrouter.ai)
|
| 1039 |
+
- UI framework by [Gradio](https://gradio.app)
|
| 1040 |
+
- Inspired by the strength and resilience of fibromyalgia warriors
|
| 1041 |
+
|
| 1042 |
+
---
|
| 1043 |
+
|
| 1044 |
+
|
| 1045 |
+
<div align="center">
|
| 1046 |
+
|
| 1047 |
+
### π Made with empathy for warriors living with fibromyalgia
|
| 1048 |
+
|
| 1049 |
+
*Your experience is valid. You are not alone. Your strength inspires us.*
|
| 1050 |
+
|
| 1051 |
+
---
|
| 1052 |
+
|
| 1053 |
+
**[β¬ Back to Top](#-hellofibro)**
|
| 1054 |
+
|
| 1055 |
+
</div>
|