-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPRD.txt
More file actions
751 lines (589 loc) · 22.4 KB
/
Copy pathPRD.txt
File metadata and controls
751 lines (589 loc) · 22.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
# DermaCheck Educational App - Product Requirements Document
## Executive Summary
**Product Name:** DermaCheck Educational App
**Vision:** An educational mobile application that helps users learn about skin conditions and empowers them to make informed decisions about seeking professional dermatological care.
**Core Principle:** This is an educational tool, NOT a diagnostic device. It teaches users dermatology concepts and helps them track skin changes over time, always directing them to healthcare professionals for actual diagnosis and treatment.
**Competition Entry:** MedGemma Impact Challenge (Kaggle)
**Target Completion:** February 24, 2026
---
## Problem Statement
**Current Challenges:**
- Dermatology wait times average 4-8 weeks in many areas
- People don't know when a skin concern warrants immediate vs. routine consultation
- Lack of skin health education leads to delayed care for serious conditions
- Underserved communities have limited access to dermatology information
- Many people don't know what to look for when self-monitoring moles/lesions
**Our Approach:**
Rather than attempting diagnosis, we educate users about dermatological features and empower them to be better advocates for their skin health when they DO see a professional.
---
## Product Goals & Objectives
### Primary Goals:
1. **Educate** users about common skin conditions and dermatological terminology
2. **Empower** users to track skin changes over time with structured documentation
3. **Guide** users on when to seek professional care (urgency levels)
4. **Reduce** health disparities through accessible skin health education
### Non-Goals (Critical Safety Boundaries):
- ❌ Provide diagnoses
- ❌ Recommend treatments
- ❌ Replace professional medical advice
- ❌ Make clinical decisions
- ❌ Store PHI/medical records (HIPAA complexity)
---
## Target Users
### Primary Personas:
**1. Health-Conscious Individual (25-45)**
- Wants to monitor moles/skin changes
- Proactive about health
- Has smartphone access
- May lack health insurance or dermatology access
**2. Parent/Caregiver (30-50)**
- Monitoring children's rashes, skin conditions
- Wants to know if doctor visit is needed
- Needs educational resources about pediatric skin issues
**3. Underserved Community Member**
- Limited healthcare access
- Language barriers
- May have darker skin tones (often underrepresented in dermatology resources)
- Needs educational materials in multiple languages
---
## Features & Functionality
### MVP Features (Phase 1)
#### 1. **Skin Photo Analysis & Education**
**Functionality:**
- User uploads/takes photo of skin area
- AI describes observable features using dermatological terminology:
- Symmetry/asymmetry
- Border regularity
- Color variation
- Approximate diameter
- Surface texture observations
- App explains what each feature means educationally
- Shows similar reference images from educational database
- **Explicitly states: "This is NOT a diagnosis"**
**User Flow:**
```
1. User taps "Learn About a Skin Concern"
2. Takes photo or uploads from gallery
3. Crop/zoom to area of interest
4. AI analyzes observable features
5. Results shown with educational context:
- "I observe: asymmetrical borders"
- "What this means: Symmetry is one feature dermatologists examine..."
- "Similar educational examples: [reference images]"
6. Educational recommendation:
- "Features observed may warrant professional evaluation"
- "Schedule appointment with dermatologist"
```
#### 2. **Tracking & Comparison Tool**
**Functionality:**
- Users create "spots" to track over time
- Name/label each tracked spot (e.g., "left shoulder mole")
- Timeline view showing progression
- Side-by-side comparison feature
- Visual change detection highlighting
- Export timeline as PDF for doctor visits
**Safety Features:**
- All stored locally on device (privacy)
- Optional cloud backup (encrypted)
- Data export for medical appointments
- No sharing/social features
#### 3. **Educational Content Library**
**Functionality:**
- Searchable library of skin conditions
- Categories: moles, rashes, infections, inflammatory, cancerous
- Each condition includes:
- Clinical photos (various skin tones)
- Description in plain language
- Common features
- When to seek care
- Risk factors
- **Clear disclaimer this is educational only**
**Content Sections:**
- "Understanding the ABCDE Rule" (melanoma screening)
- "Common Benign Conditions"
- "When to See a Doctor Urgently"
- "Skin Cancer Warning Signs"
- "Skin Types & Sun Protection"
#### 4. **Care Guidance (Triage Education)**
**Functionality:**
Three-tier educational guidance system:
**🔴 Seek Immediate Care:**
- Rapidly growing lesions
- Bleeding that won't stop
- Signs of infection with fever
- Sudden changes in existing moles
- **Action: "Visit emergency room or urgent care today"**
**🟡 Schedule Professional Consultation:**
- New or changing moles
- Persistent rashes
- Unusual skin changes
- Family history of skin cancer
- **Action: "Schedule dermatology appointment within 2-4 weeks"**
**🟢 Monitor & Learn:**
- Stable, long-existing marks
- Minor cosmetic concerns
- General skin health questions
- **Action: "Continue monitoring, educate yourself, mention at next checkup"**
**Critical Safety Feature:**
- System defaults to higher urgency when uncertain
- Always includes: "When in doubt, consult a healthcare professional"
#### 5. **Disclaimers & Safety Messaging**
**On Every Screen:**
- Footer: "Educational tool only - Not for diagnosis"
**Before First Use:**
- Comprehensive disclaimer modal:
- Purpose: Education and tracking
- Not a medical device
- Not a substitute for professional care
- Accuracy limitations
- User agreement required
**On Results:**
- Large banner: "These observations are educational only. Consult a dermatologist for diagnosis."
- Link to find dermatologists (via external service)
---
### Phase 2 Features (Post-Competition)
- Multi-language support (Spanish, Mandarin, Hindi)
- Offline mode with downloaded educational content
- Body map for tracking multiple lesions
- Reminders for self-examinations
- Integration with telemedicine platforms
- Accessibility features (voice descriptions)
---
## User Stories
### Core User Journeys:
**Story 1: Learning About a Mole**
```
As a user concerned about a mole,
I want to learn what features dermatologists look for,
So I can make an informed decision about seeking professional care.
Acceptance Criteria:
- User can photograph mole
- App describes observable features with educational context
- App provides ABCDE rule explanation
- App recommends professional consultation for evaluation
- Clear disclaimers present throughout
```
**Story 2: Tracking a Spot Over Time**
```
As a user monitoring a skin spot,
I want to track changes over weeks/months,
So I can share progression data with my dermatologist.
Acceptance Criteria:
- User can create named tracking spots
- Upload multiple photos over time
- View side-by-side comparisons
- See timeline visualization
- Export PDF report for doctor
```
**Story 3: Understanding When to Seek Care**
```
As a parent with a child's rash,
I want to understand urgency levels,
So I know whether to call the doctor today or monitor.
Acceptance Criteria:
- Educational guidance on urgency indicators
- Clear action items for each level
- Examples of conditions requiring immediate vs routine care
- Resources for finding care providers
```
---
## Technical Architecture
### Tech Stack
#### **Frontend - Mobile App**
**Framework:** React Native (cross-platform iOS/Android)
- **Rationale:** Single codebase, good MedGemma integration, large community
**Key Libraries:**
- `react-native-camera` - Photo capture
- `react-native-image-picker` - Gallery access
- `react-native-fs` - Local file storage
- `react-native-vector-icons` - UI icons
- `react-native-pdf` - PDF export
- `@react-navigation` - Navigation
**UI Framework:** React Native Paper (Material Design)
#### **AI/ML Backend**
**Primary Model:** MedGemma 1.5 4B
- **Usage:** Image analysis and feature description
- **Deployment:** Cloud-based API (Vertex AI or HuggingFace Inference)
**Secondary Model:** MedSigLIP (if needed)
- **Usage:** Image encoding/embedding for similarity search
**Inference Options:**
1. **Cloud API** (MVP approach):
- Google Cloud Vertex AI
- Lower latency, always up-to-date model
- Requires internet connection
- Cost per request
2. **On-Device** (Phase 2):
- TensorFlow Lite conversion
- Offline capability
- Privacy benefits
- Larger app size, slower inference
**For MVP: Cloud API approach**
#### **Backend Services**
**API Layer:** Node.js + Express
- Handles MedGemma API calls
- Rate limiting
- Usage analytics (anonymous)
- Content delivery
**Database:** Firebase Firestore (optional cloud backup)
- User tracking data (encrypted)
- Sync across devices
- Real-time updates
**Storage:**
- **Primary:** Local device storage (SQLite + filesystem)
- **Optional Backup:** Firebase Storage (encrypted)
**Hosting:**
- Backend API: Google Cloud Run (serverless)
- Static content: Firebase Hosting
#### **Educational Content**
**Content Database:**
- Structured JSON files
- Curated dermatology educational content
- Reference images (open-source medical image datasets)
**Sources:**
- DermNet NZ (open educational resource)
- AAD (American Academy of Dermatology) public materials
- NIH MedlinePlus
- **All properly attributed and licensed**
---
### System Architecture Diagram
```
┌─────────────────────────────────────────┐
│ React Native Mobile App │
│ ┌─────────────────────────────────┐ │
│ │ UI Components │ │
│ │ - Camera Interface │ │
│ │ - Photo Gallery │ │
│ │ - Timeline View │ │
│ │ - Educational Content │ │
│ └─────────────────────────────────┘ │
│ ↓ │
│ ┌─────────────────────────────────┐ │
│ │ Local Storage (SQLite) │ │
│ │ - Tracking data │ │
│ │ - Photos (encrypted) │ │
│ │ - User preferences │ │
│ └─────────────────────────────────┘ │
└─────────────────┬───────────────────────┘
│
↓ HTTPS
┌─────────────────────────────────────────┐
│ Backend API (Node.js/Express) │
│ │
│ ┌──────────────────────────────────┐ │
│ │ Endpoints: │ │
│ │ - POST /analyze-image │ │
│ │ - GET /educational-content │ │
│ │ - POST /generate-report │ │
│ └──────────────────────────────────┘ │
└────────┬──────────────┬─────────────────┘
│ │
↓ ↓
┌─────────────────┐ ┌──────────────────┐
│ Vertex AI │ │ Firebase │
│ (MedGemma) │ │ - Firestore │
│ - Image │ │ - Storage │
│ Analysis │ │ - Auth (future) │
│ - Feature │ │ │
│ Extraction │ │ │
└─────────────────┘ └──────────────────┘
```
---
### MedGemma Integration
#### **Image Analysis Pipeline:**
```python
# Pseudocode for image analysis
def analyze_skin_image(image_path):
"""
Educational analysis of skin image using MedGemma
Returns observable features with educational context
"""
# 1. Prepare prompt for MedGemma
prompt = """
You are an educational tool helping users learn about skin features.
Analyze this image and describe OBSERVABLE features only.
Use dermatological terminology but explain each term.
Describe:
- Symmetry (is it symmetrical or asymmetrical?)
- Borders (are they regular, irregular, or poorly defined?)
- Color (single color or multiple colors? Which?)
- Diameter (approximate size)
- Evolution indicators (any signs of change?)
- Texture (flat, raised, rough, smooth?)
Format response as educational observations, NOT diagnosis.
End with: "Consult a dermatologist for professional evaluation."
"""
# 2. Call MedGemma API
response = medgemma_client.analyze(
image=image_path,
prompt=prompt,
max_tokens=500
)
# 3. Parse response
features = parse_features(response.text)
# 4. Add educational context
educational_content = add_context(features)
# 5. Determine guidance level (conservative approach)
guidance = determine_guidance(features) # Defaults to "seek consultation"
return {
"observations": educational_content,
"guidance": guidance,
"disclaimer": "This is educational only. Not a diagnosis.",
"raw_description": response.text
}
```
#### **API Request Flow:**
1. **User takes photo** → Compress to <2MB
2. **Upload to backend** → Encrypted HTTPS
3. **Backend calls MedGemma** → Vertex AI endpoint
4. **Parse response** → Extract features, add disclaimers
5. **Return to app** → Display with educational context
6. **Save locally** → Store result with photo
#### **Cost Estimation:**
- Vertex AI MedGemma pricing: ~$0.001-0.005 per image
- Target: 10,000 analyses = $10-50 budget
- Optimization: Cache educational content, batch requests
---
## Data & Privacy
### Data Handling
**What We Store Locally:**
- User-captured photos (encrypted)
- Tracking history and labels
- AI analysis results
- User preferences
**What We DON'T Store:**
- Personal identifying information (PII)
- Health records
- Diagnosed conditions
- User names/emails (unless they opt-in for cloud backup)
### Privacy Approach
**Default: Local-First**
- All data stored on device
- No account required
- No cloud upload unless explicitly opted-in
**Optional Cloud Backup:**
- End-to-end encryption
- User controls all data
- Easy data deletion
- Export all data feature
### Compliance Considerations
**Not a Medical Device:**
- Educational tool exemption
- No diagnostic claims
- Clear disclaimers throughout
- FDA registration NOT required (educational use)
**Privacy Laws:**
- GDPR compliant (EU users)
- CCPA compliant (CA users)
- Data minimization approach
- User data control
**Terms of Service:**
- Educational purposes only
- No warranty on accuracy
- User assumes all risk
- Liability limitations
---
## Safety & Risk Management
### Safety Features
#### **1. Conservative Defaults**
- When uncertain → recommend professional consultation
- All unusual features → flag for evaluation
- System bias toward caution
#### **2. Multi-Layer Disclaimers**
- Launch screen agreement
- Every analysis result page
- Export reports
- Settings reminder
#### **3. No False Reassurance**
- Never say "this looks normal"
- Never say "no need to worry"
- Always: "Observable features suggest X, consult professional"
#### **4. Prominent "Get Help" Button**
- Always visible
- Links to:
- Find a dermatologist (AAD tool)
- Telehealth options
- Emergency resources
#### **5. Accuracy Transparency**
- "AI systems can make mistakes"
- "Lighting, angle affect analysis"
- "Always get professional evaluation"
### Risk Mitigation
| Risk | Likelihood | Impact | Mitigation |
|------|------------|--------|------------|
| User treats as diagnosis | High | Severe | Multiple disclaimers, no diagnostic language, always recommend consultation |
| Delayed care from false reassurance | Medium | Severe | Never reassure, always suggest professional evaluation, conservative guidance |
| Poor quality photos | High | Low | Photo quality tips, retake prompts, lighting guidance |
| Misuse for serious conditions | Medium | High | Urgent care guidance prominent, red flag symptoms listed |
| Liability claims | Low | Medium | Strong TOS, educational disclaimers, no medical claims |
| Model bias (skin tone) | Medium | High | Diverse reference images, acknowledge limitations, test across skin types |
---
## Success Metrics
### Competition Metrics
**Primary (for judging):**
- **Impact**: User testimonials, use cases, potential reach
- **Innovation**: Novel use of MedGemma for education
- **Implementation**: Working demo, code quality
- **Safety**: Comprehensive safety approach
- **Presentation**: Clear documentation, demo video
### Product Metrics
**User Engagement:**
- Daily active users (DAU)
- Photos analyzed per user
- Tracking spots created
- Educational content views
- Time spent in app
**Educational Impact:**
- User survey: "Did this help you learn about skin health?"
- "Did this help you decide whether to see a doctor?"
- App store ratings/reviews
- Testimonials
**Safety Metrics:**
- Zero incidents of delayed care (user surveys)
- Disclaimer view rate: 100%
- Professional consultation rate after using app
**Technical:**
- App crashes: <1%
- API response time: <3 seconds
- Photo analysis accuracy: Validated against dermatology textbooks
- Model performance across skin tones: Measure & report
---
## Development Timeline
### Week 1-2: Foundation (Jan 20 - Feb 2)
- [ ] Set up React Native project
- [ ] Design UI/UX mockups
- [ ] Create disclaimer/legal copy
- [ ] Set up Vertex AI MedGemma access
- [ ] Build basic camera interface
### Week 3-4: Core Features (Feb 3 - Feb 16)
- [ ] Implement photo capture/gallery
- [ ] Build MedGemma integration
- [ ] Create analysis results screen with disclaimers
- [ ] Implement local storage (SQLite)
- [ ] Build tracking timeline feature
- [ ] Develop educational content library (10-15 conditions)
### Week 5: Polish & Safety (Feb 17 - Feb 23)
- [ ] Add all disclaimer screens
- [ ] Implement urgency guidance system
- [ ] Create PDF export feature
- [ ] Build onboarding flow
- [ ] User testing with 10-15 people
- [ ] Bug fixes and refinements
### Week 6: Submission (Feb 24)
- [ ] Final testing
- [ ] Create demo video
- [ ] Write documentation
- [ ] Prepare presentation
- [ ] Submit to Kaggle
---
## Competition Deliverables
### Required Submissions:
1. **Working Application**
- APK file (Android) or TestFlight link (iOS)
- Source code on GitHub
- README with setup instructions
2. **Demo Video (3-5 min)**
- Problem statement
- Solution walkthrough
- Key safety features
- MedGemma integration demo
- Impact potential
3. **Documentation**
- Technical architecture
- MedGemma usage explanation
- Safety/ethical considerations
- User testing results
- Future roadmap
4. **Presentation Deck**
- Problem & solution
- Technical approach
- Demo screenshots
- Impact metrics
- Q&A prep
---
## Competitive Advantages
### Why This Could Win:
1. **Safety-First Design**
- Explicitly educational, not diagnostic
- Reduces liability while maximizing impact
- Sets ethical standard
2. **Underserved Focus**
- Addresses health disparities
- Multi-skin-tone education
- Accessible interface
3. **Novel MedGemma Use**
- Uses multimodal capabilities (images + text)
- Educational context generation
- Feature extraction for learning
4. **Practical Utility**
- Solves real problem (when to see doctor?)
- Tracking for doctor visits
- Actionable guidance
5. **Scalability**
- Mobile-first
- Minimal backend costs
- Open-source potential
---
## Future Enhancements (Post-Competition)
### Phase 2 Features:
- Full offline mode with on-device MedGemma
- 10+ language support
- Body map visualization
- Telemedicine integration
- Pediatric skin condition focus
- Accessibility features (screen reader, voice)
### Potential Partnerships:
- Dermatology associations for content validation
- Community health centers for distribution
- Medical schools for education
- Open-source community contribution
### Monetization (if deployed):
- Free base app (educational mission)
- Optional premium: Cloud backup, unlimited tracking, advanced features
- Institutional licenses for clinics/schools
- Grant funding for underserved deployment
---
## Open Questions & Decisions Needed
**Technical:**
- [ ] Which cloud platform? (Google Cloud vs AWS vs Azure)
- [ ] Image size/compression standards?
- [ ] Offline capabilities in MVP?
**Content:**
- [ ] How many skin conditions in initial library?
- [ ] Which languages for Phase 1?
- [ ] Partner with dermatologist for content review?
**Legal:**
- [ ] Need lawyer review of disclaimers?
- [ ] Insurance needed for app?
- [ ] Age restrictions (13+, 18+)?
**UX:**
- [ ] Mandatory tutorial before first use?
- [ ] Gamification elements for engagement?
- [ ] Community features (safe to add)?
---
## Team Roles (if applicable)
**Solo Developer Path:**
- Focus on core MVP features
- Use pre-built UI components
- Leverage MedGemma for intelligence
- Community content for education
**Team Path:**
- **Developer:** React Native app + backend
- **Designer:** UI/UX, educational content design
- **Medical Advisor:** Content validation, safety review
- **Product:** PRD, demo video, presentation
---
## Conclusion
DermaCheck Educational App provides a **safe, impactful, and technically feasible** entry for the MedGemma Impact Challenge. By focusing strictly on education rather than diagnosis, we:
✅ Minimize medical/liability risks
✅ Maximize social impact (health education access)
✅ Showcase MedGemma's multimodal capabilities
✅ Create a scalable, deployable solution
✅ Address real healthcare disparities
The conservative, educational-only approach makes this buildable within the competition timeline while maintaining the highest ethical standards.
---
**Next Steps:**
1. Review and approve this PRD
2. Set up development environment
3. Create detailed UI mockups
4. Begin Week 1 tasks
5. Schedule check-ins (weekly progress reviews)