Skip to content
Panotxa

The science

What happens after you photograph a meal

Every step between your photo and the verdict. Plain words first, then the formulas, the measurements and the limits we know about.

Watch the 90-second explainer

Last reviewed on 26 September 2026, against the app as it runs today.

The science in 90 seconds

The same steps as this page, on one real plate.

What the video says
  1. What's behind one photo? A 90-second look at how Panotxa reads a meal.
  2. It starts on your phone. The photo is resized, and hidden data like your location is removed.
  3. One AI reading. Google Gemini fills in more than 50 named fields, with a confidence for each part.
  4. Portions are estimates. No scale, no food database: typical values for the foods it can see. Cooking oil is hard to see, what's underneath is hidden, and there is no reference for the plate size.
  5. Seven parts, one score. A fixed formula weighs what the AI saw: balance 42%, processing 23%, drinks 10%, completeness 10%, portion 8%, boosters 7%, and sugar as a penalty.
  6. 70% formula, 30% AI. The model's overall judgement counts, but the transparent formula leads. Dish quality from 1 to 99.
  7. A verdict in words. Four zones, from Needs work to Excellent, with one tip for next time.
  8. You can correct it. Add context and it analyses again. Rename a dish and later photos remember it.
  9. Trends do the coaching. Momentum follows your last week, Habit your last six weeks.
  10. What we measured. 15 plates scored by a nutritionist and by the app: 11.9 points apart on average, out of 100 (15 of our own plates, one nutritionist, September 2026).
  11. Every number, with its source: panotxa.com/science.

From photo to verdict, step by step

The AI does the looking. Everything after that is fixed arithmetic that always gives the same result for the same answers, and it is written out below.

  1. Your phone prepares the photo

    Before uploading, the app resizes the photo to at most 1080 pixels on its long side and saves it again. That drops the hidden data a camera adds, including where it was taken.

  2. One AI reading

    The server shrinks it to at most 768 pixels and sends it to Google's Gemini model (today Gemini 3.5 Flash-Lite) with fixed instructions, the meal type and your language. The answer has more than 50 named fields: what the dish is, its ingredients, how the plate splits into vegetables, fruit, grains and protein, how processed it is, how it was cooked, the portion, the drink, and how confident the model is about each part.

  3. Sanity checks

    If the model is less than 60% sure the photo shows food, nothing is scored. A photo of leftovers (shells, bones, peel) is read as the food you ate, with low confidence in the portion. A table served for several people counts one portion for you. A photo with several dishes shows you what it found and waits for your OK before scoring.

  4. Seven sub-scores

    A fixed formula turns the answer into seven sub-scores from 0 to 100: balance, processing, portion, drinks, sugar, boosters and completeness. A part the model was unsure about (confidence under 60) counts for less.

  5. Formula first, AI second

    The dish score is 70% formula and 30% the model's own overall estimate, kept between 1 and 99. For a meal with several dishes, their fields are pooled before scoring, so fish next to a salad counts as one balanced meal, not two incomplete ones. When you finish the meal, a second AI reading of all its dishes gives that 30%.

  6. A verdict in words

    The score lands in one of four zones, from Needs work to Excellent, with tips for next time. In Habits mode you see the word, not the number.

Technical note: the fields and the formula

The instructions ask for a JSON answer with fixed keys. A test in the code fails if an edit to the instructions ever drops one of the 56 fields the formula reads.

Balance = 0.18 × vegetable share + 0.22 × plant share + 0.25 × protein quality + 0.18 × whole grains (0 or 100) + 0.17 × fruit (0 or 100), plus up to 10 points for colour variety.

Processing starts at 100 and loses 15 points per NOVA level above 1, 12 for frying, 8 for breading and up to 20 for visible oil. Gentle cooking adds points: raw 10, steamed 8, boiled 6, baked or grilled 4, sautéed 2.

Dish score for a main meal = 0.42 × balance + 0.23 × processing + 0.08 × portion + 0.10 × drinks + 0.07 × boosters + 0.10 × completeness, minus up to 4.5 points for added sugar or a dessert. Then 70% of that plus 30% of the model's own estimate.

These weights are the current preset (v5). They were first calibrated in January 2026 against scores from a nutritionist who works with us.

Where the portion and nutrition numbers come from

Panotxa does not weigh your food and does not look it up in a food composition database. The same AI reading that names the dish also estimates the portion in grams, the calories, protein, carbohydrates, fat, fibre and added sugar, from typical values for the foods it recognises, and says how confident it is about the calories.

So every number is an estimate. In Habits mode, the default, you never see calories: the verdict depends mostly on what is on the plate and how it was cooked, and the portion is 8% of a dish score. Fitness mode shows the numbers.

A short note fixes most of these. “Add context” takes things like “Cooked in olive oil” or “Restaurant portion (~1.5×)”, and the dish is analysed again with it.

Technical note: consistency is not accuracy

Calories and macronutrients must agree with each other. In our September 2026 test, protein × 4 + carbohydrates × 4 + fat × 9 came within 20% of the stated calories on all 25 food photos.

That shows the numbers are consistent, not that they match the plate. We have no weighed meals to compare with, so we publish no accuracy figure for calories or grams.

What a photo cannot show

  • Oil, butter or sugar absorbed in cooking or mixed into a sauce.
  • What is under the top layer: rice under a curry, the filling of a pie.
  • Scale. Without something to compare with, a small plate up close and a big plate further away can look alike.
  • What is in a glass or a mug: milk or a plant drink, sugar or none.

How the quality score is built

The score answers one question: how good was this meal, for this type of meal? Its reference points come from public nutrition science: the Harvard Healthy Eating Plate for balance, the NOVA classification for processing.

Weights for a main meal

  • Balance42%Vegetables, fruit, whole grains, the quality of the protein, plants overall and colour variety.
  • Processing23%The four NOVA levels, plus frying, breading and visible oil. Gentle cooking earns points.
  • Drinks10%Water 100, unsweetened drinks 90, alcohol 50, sugary drinks 40. No drink is neutral.
  • Completeness10%Good protein together with vegetables or fruit, rather than either one alone.
  • Portion8%Moderate portions and lower energy density. On a shared table, your portion replaces the table's.
  • Boosters7%Fermented foods, nuts and seeds, olive oil.
  • Sugar−4.5Added sugar or a dessert takes off up to 4.5 points.

Why 70% formula and 30% AI

The formula is transparent and stable: the same answers always give the same score. The model's overall estimate catches what a fixed formula misses, such as a dish that is better or worse than the sum of its parts. Capping the AI at 30% keeps the formula in charge.

Four zones

  • Excellent80 to 99
  • Good60 to 79
  • Fair40 to 59
  • Needs work1 to 39

Fair to real life

  • Snacks are judged as snacks: an apple or a handful of nuts can score high on its own.
  • A coffee or a glass of water on its own is scored as a drink, so logging it does not pull your day down.
  • A shared paella counts one portion for you, not the whole pan.
  • Guidance from a nutritionist you connect with tailors the advice. The instructions forbid it from changing the score.
Technical note: snacks and drinks

Snack balance starts at 50 and adds credit for each good part: fruit 35, vegetables 25, nuts or seeds 25, fermented foods 20, good protein 20, whole grains 15. Completeness is not required, and the sugar penalty doubles.

A drink on its own is scored on the drink: water 100, unsweetened 90, alcohol 50, sugary 40, minus 15 for added sugar, 10 for ultra-processing and 10 for a milkshake-style dessert drink. A plain coffee lands around 90.

How your targets are calculated

Habits mode sets no calorie target at all. Fitness mode does, from published equations and defaults you can change.

Resting energy
The Mifflin-St Jeor equation from your weight, height, age and sex: 10 × kg + 6.25 × cm − 5 × age, then + 5 for men or − 161 for women.
Daily energy
Resting energy × an activity factor, from 1.2 (sedentary) to 1.9 (extra active).
Calorie goal
Daily energy minus or plus your chosen weekly pace, at 7,700 kcal per kg, and never below 1,200 kcal a day when losing weight.
Measured resting energy
If a professional you connect with records a measured value, for example from a body-composition scale, it replaces the equation while you stay connected.
Protein
1.2 g per kg of body weight by default, adjustable from 0.5 to 3.5 g/kg, or per kg of lean mass if you log body fat. For context: 0.8 g/kg is the minimum set by the Institute of Medicine, 1.0 to 1.2 g/kg is recommended for older adults (ESPEN), 1.4 to 2.0 g/kg for people who exercise (ISSN), and 2.3 to 3.1 g/kg of lean mass while dieting with training (ISSN, Helms).
Carbohydrates and fat
45% and 30% of the calorie goal, inside the ranges the Institute of Medicine considers acceptable (45 to 65% and 20 to 35%).
Fibre
14 g per 1,000 kcal, the basis of the Institute of Medicine's adequate intake.
Weight
The weight tile shows your 7-day average, because a daily reading can swing by a kilo or more with water and food. Time to target comes from your measured trend, not from the 7,700 kcal rule.

These are equations for populations, and your real needs can differ. The 7,700 kcal per kg rule is a simplification: weight loss slows as the body adapts (Hall and colleagues, 2011), which is why projections use your measured weight.

Accuracy and limits: what we measured

On 24 September 2026 we ran the production setup (the same model, instructions and formula) on a fixed set of our own photos, and compared the results with a nutritionist's scores and with two independent AI reviewers.

Quality score
On 15 plates, Panotxa's score was 11.9 points away from the nutritionist's on average, on the 0 to 100 scale (correlation 0.85). It put 5 of the 15 plates in the same zone as she did, and none more than one zone away.
Where it differs
The gap has a pattern. Panotxa is stricter on the healthiest plates (she rated seven Excellent, Panotxa none) and kinder on fried or processed ones. The other AI models we tested showed the same gap, so the fix belongs in the formula, not in a different model.
Food or not
All 25 photos were told apart correctly, including plastic food models and a field of sunflowers.
Invented details
The reviewers checked 158 specific statements the app made about the photos. 11% were not supported by the photo, most often a likely but invisible ingredient such as olive oil.
Calories and grams
Not measured. We have no weighed meals to compare with, so we publish no accuracy figure for them.

Nutritionist and Panotxa, plate by plate

Nutritionist and Panotxa, plate by plateScatter plot of 15 plates. Nutritionist's scores and Panotxa's scores: 70 and 73, 30 and 42, 80 and 70, 20 and 39, 30 and 39, 50 and 73, 60 and 49, 50 and 40, 60 and 65, 90 and 78, 80 and 62, 80 and 78, 90 and 71, 100 and 79, 80 and 76.002020404060608080100100Nutritionist's scorePanotxa's scoresame score
15 of our own plates, one nutritionist, 24 September 2026. Dots above the dashed line: Panotxa scored higher.
How the test was run

37 photos: 16 of our own plates (15 with a nutritionist's score), 3 edge cases, 6 photos of things that are not food and 12 photos of menus and food counters. Only our own or openly licensed photos, never user photos.

The two reviewers were OpenAI GPT-6 Sol and Anthropic Claude Opus 5.5, neither of them the model Panotxa uses. Their own quality scores agreed with the nutritionist no better than Panotxa's did, so for quality we trust only hers.

Read these numbers as a direction, not a guarantee: 15 plates and one nutritionist is a small sample. We run the same test on every new model before considering it.

Correcting it, and what happens to your corrections

The AI will get things wrong. Fixing it takes a tap, and everything downstream follows.

Rename a dish
Tap the title, type the right name, and the dish is analysed again with it.
Add context
“Add context” takes a note such as “Side of bread not pictured” and analyses the dish again with it.
Check what it found
On a photo with several dishes, “What we found” lists them. Remove one, or add what it missed with “We missed something”, before anything is scored.
Answer one question
When it is unsure, it asks: “Is this actually…?” for a dish that could be two different things, or “Is this all yours?” for a shared table.
Everything updates
Scores, totals and your Momentum and Habit are recalculated after every correction.

How corrections are reused

Your renames are remembered. Before each new photo, the model is told about up to 5 of your corrections from the last 90 days, so next time it prefers your version. That is the only way corrections are reused: Panotxa does not train any AI model on your meals.

Your photos

  • Resized on your phone and stripped of hidden data, including location, before upload.
  • Sent to Google's Gemini API only to be analysed, at most 768 pixels on the long side.
  • Not used to train AI models, by us or by Google: its paid API terms exclude it.
  • Kept so you can see your meals, and deleted when you delete your account.
  • The AI's requests and answers are logged so we can find and fix bad answers.
  • Seen by a professional only if you connect with one and choose to share your meals.
Full details in the privacy policy →

References

The published work behind the formulas and defaults on this page.

  1. Resting energy in Fitness mode

    Mifflin MD, St Jeor ST, Hill LA, et al. A new predictive equation for resting energy expenditure in healthy individuals. Am J Clin Nutr. 1990;51(2):241-247.

    doi.org/10.1093/ajcn/51.2.241
  2. The four processing levels

    Monteiro CA, Cannon G, Levy RB, et al. Ultra-processed foods: what they are and how to identify them. Public Health Nutr. 2019;22(5):936-941.

    doi.org/10.1017/S1368980018003762
  3. The balance of the plate

    Harvard T.H. Chan School of Public Health. Healthy Eating Plate.

    nutritionsource.hsph.harvard.edu/healthy-eating-plate/
  4. Protein minimum, carbohydrate and fat ranges, fibre

    Institute of Medicine. Dietary Reference Intakes for Energy, Carbohydrate, Fiber, Fat, Fatty Acids, Cholesterol, Protein, and Amino Acids. National Academies Press; 2005.

    doi.org/10.17226/10490
  5. Protein for people who exercise and while dieting

    Jäger R, Kerksick CM, Campbell BI, et al. International Society of Sports Nutrition Position Stand: protein and exercise. J Int Soc Sports Nutr. 2017;14:20.

    doi.org/10.1186/s12970-017-0177-8
  6. Protein for older adults

    Deutz NEP, Bauer JM, Barazzoni R, et al. Protein intake and exercise for optimal muscle function with aging: Recommendations from the ESPEN Expert Group. Clin Nutr. 2014;33(6):929-936.

    doi.org/10.1016/j.clnu.2014.04.007
  7. Protein per kg of lean mass

    Helms ER, Aragon AA, Fitschen PJ. Evidence-based recommendations for natural bodybuilding contest preparation: nutrition and supplementation. J Int Soc Sports Nutr. 2014;11:20.

    doi.org/10.1186/1550-2783-11-20
  8. Why the 7,700 kcal rule is only a starting point

    Hall KD, Sacks G, Chandramohan D, et al. Quantification of the effect of energy imbalance on bodyweight. Lancet. 2011;378(9793):826-837.

    doi.org/10.1016/S0140-6736(11)60812-X
  9. Google does not train on paid API data

    Google. Gemini API Additional Terms of Service, “How Google Uses Your Data” (Paid Services).

    ai.google.dev/gemini-api/terms

Start with your next meal

Try it free

7-day free trial · No card needed