Root cause: When Gemini was unavailable (geo-restriction), the fallback
report used a static template with hardcoded N/A for every field, ignoring
the actual patient data that was correctly sent in the request body.
Fix: Replaced the static FALLBACK_VERDICT with a buildDynamicFallback()
function that generates a complete 11-section report from the actual
patientData, audioAnalysis, asthmaAssessment, and environmentalData.
Changes:
- src/app/api/generate-ai-verdict/route.ts: dynamic fallback builder,
debug logging (payload, prompt, response), descriptive error messages
- src/components/breathe/views/AIDoctorView.tsx: show real Gemini error
to user when fallback is used (instead of silent 'unavailable')
Result: Zero N/A fields in the report when assessment data exists.
The report shows real Age, BMI, Audio Prediction, Asthma Prediction,
AQI, PM2.5, etc. from the completed modules.