T.S
← All Projects/AI Nutrition Coach
AI2025·Full Stack Developer

AI Nutrition Coach

Vision-powered calorie tracking that never hallucinates

Next.jsFastAPIOpenAI APIPythonPydanticUSDA FoodData Central
AI Nutrition Coach
01 —Overview

An AI nutrition coach built around one architectural rule: separate seeing from calculating. GPT identifies food items and portion sizes from a photo; every calorie and macro number comes straight from USDA FoodData Central, never from the LLM. Photo logging, an AI coaching agent, goal tracking, and a clinician dashboard ship as four fully-built phases.

02 —The Challenge

Vision-LLM food logging apps are prone to confidently hallucinated calorie and macro numbers. The goal was a nutrition coach accurate enough for real tracking — and eventually clinical use — where every number is traceable to real scientific data, not a model's guess.

03 —The Solution

Split the pipeline into two stages: Stage 1 uses GPT purely for food identification and gram-level portion estimation — it never touches a calorie or macro figure. Stage 2 matches each identified food against USDA FoodData Central and computes macros directly (per_100g × portion_grams / 100). On top of that grounded core: a photo → identify → USDA-ground → edit/confirm flow with confidence badges and daily rings; an AI coaching agent with full meal history in context, streaming responses, and proactive nudges (e.g. flagging a protein shortfall); an onboarding wizard computing TDEE via Mifflin-St Jeor with auto-generated macro targets, adherence tracking, and streaks; and a role-based clinician dashboard with invite-based patient linking, target overrides, and clinical notes. Every phase was built spec-first — DB schema, Pydantic models, API shapes, UI layout, and a verification checklist written before any code.

04 —Key Results
01Zero hallucinated numbers — macros computed from USDA FoodData Central, not the LLM
024 phases fully shipped: photo logging, AI coaching agent, goals & progress, clinician dashboard
03Proactive AI coaching nudges driven by full meal history in context
04TDEE-based goal wizard (Mifflin-St Jeor) with adherence tracking and streaks
0554 tests passing in CI with zero real API calls (mocked vision + USDA providers)
05 —Screenshots
AI Nutrition Coach screenshot 1
AI Nutrition Coach screenshot 2
AI Nutrition Coach screenshot 3
AI Nutrition Coach screenshot 4
AI Nutrition Coach screenshot 5
AI Nutrition Coach screenshot 6
AI Nutrition Coach screenshot 7
Project Info
CategoryAI
Year2025
My RoleFull Stack Developer
Tech Stack
Next.jsFastAPIOpenAI APIPythonPydanticUSDA FoodData Central
More Projects

Like what you see?

Let's build something like this together — or something even better.

Hire MeMore Projects