Methodology

Every number, and where it came from.

engine v0.1.0 · standards set 2026-09 · last revised 3 Sep 2026

In plain words

Nothing in your report is written from a template. A deterministic engine computes every value from your answers, stores each one under a fact ID, and the writing is only allowed to explain facts that already exist. This page lists the formulas, the constants and the published source behind each one.

The short version

Your eleven answers go into lib/engine. It computes BMI against Asian-Indian cut-offs, BMR with Mifflin-St Jeor, maintenance calories from a job-based activity factor adjusted by your steps and training, a goal-adjusted target that is capped and then floored, protein and fat targets with carbohydrates as the remainder, water, steps and sleep targets, a problem list, a twelve-week programme, a meal template and ninety dated days.

Each value is stored as a fact with an ID like F.MET.TDEE. The language model receives only those facts and a schema; a validator then rejects any sentence containing a number that is not in the packet, plus a list of forbidden claims. If the validator fails twice, the report is marked failed rather than shipped.

The formula chain

WhatHowConstantFact ID
BMIweight ÷ height², classed on Asian-Indian cut-offs18.5 / 23 / 25F.MET.BMI
Waistabdominal-obesity cut-off, Indian consensus90 cm M / 80 cm FF.MET.WAIST
BMRMifflin-St Jeor on measured height, weight and age10W + 6.25H − 5A ± sF.MET.BMR
Activity factorjob factor, adjusted ±0.1 around 6,000 steps1.3–1.75F.MET.ACTIVITY
Training energyadded per planned training minute5 kcal/minF.MET.TDEE
Fat-loss targetpercentage deficit, capped in absolute kcal−20 %, cap 750 kcalF.MET.TARGET_KCAL
Muscle-gain targetpercentage surplus, capped in absolute kcal+10 %, cap 300 kcalF.MET.TARGET_KCAL
Calorie floorapplied after the deficit; the floor always wins1200 F / 1500 MF.MET.TARGET_KCAL
Proteingrams per kg of reference weight, by goal1.6–2 g/kgF.MET.PROTEIN_G
Fatshare of target energy, with a per-kg floor25 %E, ≥ 0.6 g/kgF.MET.FAT_G
Carbohydratethe remainder after protein and fattarget − (P×4 + F×9) ÷ 4F.MET.CARBS_G
Waterper kg bodyweight, plus a training-day bonus35 ml/kg + 500 mlF.MET.WATER_ML
Stepscurrent + 2,000, clamped7,000–10,000F.MET.STEPS
Sleepadult target range7–9 hF.MET.SLEEP
Projectionenergy balance converted to tissue, as a guide only7,700 kcal/kgF.MET.PROJ_D90_KG

Why Indian cut-offs

Asian-Indian cut-offs, not the WHO global 25/30. Indians carry more body fat and visceral fat at the same BMI and develop diabetes and CVD at lower BMI. That is why the BMI scale on every ifit90 page marks 23 and 25 rather than the global 25 and 30, and why waist is checked at 90 cm for men and 80 cm for women.

The food table is also Indian first: portions are in katori, piece and gram rather than cups, and the protein arithmetic accounts for the fact that cereals are short on lysine and pulses short on methionine — Protein quality = digestibility x limiting amino acid. Cereals (rice, wheat) are low in lysine; pulses (dal, chana, rajma) are low in methionine. Eaten together in the same day they complement (dal-chawal, rajma-chawal, idli-sambar, khichdi, chana-roti). Whole-day intake matters; same-meal pairing is not required but is convenient.

What the engine refuses

Before anything is computed, the safety gate stops the plan when:

  • the user is under 18, or pregnant;
  • BMI is below 17;
  • the answers signal disordered eating.

It caps rather than refuses when a condition is declared: the deficit is reduced, a clinician note is attached, and contraindicated movement patterns fall back to a substitute instead of being silently dropped. The calorie floor of 1200 kcal for women and 1500 kcal for men is never crossed, whatever the deficit percentage works out to.

How the mathematics is verified

The engine ships with a test suite that runs on every change and asserts the invariants rather than the outputs: macros multiplied by their energy values sum to the target within 2 %; protein and calories never fall below their floors; every week contains at least one rest day; no session prescribes equipment the user does not own; an injury flag removes the listed movements; the calendar contains exactly ninety days with no gaps or overlaps and round-trips through its time zone; every meal slot lands within 10 % of its calorie share and the day within 5 %; every problem carries at least one evidence ID; and no rendered plan shows a raw internal id in place of a title.

Six golden fixtures — a vegetarian woman losing fat at a desk job, a non-vegetarian man gaining in a full gym, a Jain intake, a hypertension case, a knee injury, a shift worker — are regenerated and verified on every run.

How the writing is constrained

The language model never computes. It receives the fact packet and a schema, and it writes headline, explanation, problem narratives, phase themes and milestone copy. A validator then checks every claim against the packet: any number that does not appear in a packet display string is a violation, as is any phrase on the forbidden list — cures, guarantees, “lose N kg in N days”, steroid and drug names, diagnosis and prescription language, “100 % accurate”, detox. One retry is allowed with the violations appended; after that the report is marked failed for a human to look at.

The limits of each number

  • BMR is an estimate derived on a US cohort; Indian adults may run 5–10 % lower. Recalibrate from two to three weeks of morning-weight trend, not from the formula.
  • Activity factor is self-reported and people over-estimate. We start one step lower than the self-report on purpose.
  • The projection at 7,700 kcal/kg is a rough guide. Expect real-world loss to run below the formula after week three or four, and expect a water swing in week one that is not fat.
  • Food values are per standard household portion; your roti is not everyone’s roti.
  • Prices are city-tier estimates for orientation, not quotes.

Sources

The full standards set, including the alternatives we did not pick and the note explaining why, ships with the product as data/standards.json (2026-09).

Terms → Privacy → About →