1. Read the intake¶
180 fields go in. About 30 of them change the menu. This step finds those 30 and writes them down in one place, so that every later step reads from a short structured digest rather than re-reading raw JSON and reaching a slightly different conclusion each time.
Write the digest even for a simple case. The steps that follow are specified against it, and half its value is that it makes the missing answers visible before any arithmetic depends on them.
The digest¶
Produce this as a working note. It is not client-facing and never ships.
## Intake digest — [name], [date]
### Who
age · gender · city · occupation · work activity · household cooking situation
### Screening → step 2
PAR-Q triggers fired · conditions · medications flag · allergies ·
GI urgent · disordered eating · menses status · consents
### Body → step 3
height cm · weight kg (measured | self-reported | missing) · BMI · waist
### Activity → step 3
currently active · sessions/week · session length · daily lifestyle ·
work activity
### Goal → step 3
primary goals · direction (deficit | maintenance | surplus) · obstacles ·
support wanted
### Protein modifiers → step 4
menses status · training load · age
### Current eating → steps 5–8
typical day · representative? · meals/day · first meal · last meal ·
weekend differs · FFQ standouts · water · caffeine · alcohol
### Constraints → step 8
pattern · intolerances · allergies · dislikes · medical diet ·
eating limitation · cooking confidence · who cooks · who shops ·
meals out/week · budget · household eating differently
### Symptoms → steps 6–8
digestive yes-answers · bowel · reflux · energy crash · sleep hours ·
sleep quality · stress · shift work · travel
### Gaps
[every field this digest wanted and did not get]
Where each line comes from¶
Who¶
client_dob → age at today's date. client_gender. client_address.
client_occupation. client_work_activity. nut_who_cooks, nut_who_shops,
client_children.
Age and gender both feed the energy equation directly. Where client_gender is
"other" or absent, see
step 3.
Screening¶
Copy every PAR-Q field verbatim — do not summarise them to "cleared". Then
health_conditions, health_diabetes_mgmt, parq_5_medication,
health_allergies, nut_intolerances, sys_gi_urgent,
nut_disordered_history, nut_medical_diet, sys_menses_status,
consent_accuracy, consent_data_processing, consent_clearance_confirm.
This block exists so step 2 can run against a short list rather than the whole file. Under-copying here is how a stop condition gets missed.
Body¶
meas_height_cm and meas_weight_kg if present.
If not, in order: the raw meas_height / meas_weight with their __unit
fields; then meas_weight_self with meas_weight_self__unit. Record which
source was used — the digest line says weight: 78 kg (self-reported), and
that provenance ends up in the menu's Assumptions.
Take meas_bmi and meas_whr as given where present. meas_waist is worth
carrying for the notes even though nothing computes from it.
meas_weight_aware governs what you may print
"Yes, but I'd rather not say", "No, and I'd rather not know", or
meas_blind_weigh = "I'd rather not be weighed at all" all mean the same
thing for the menu: the weight may be used in the arithmetic and must
never appear in the client-facing document. Not in the assumptions, not in
a note, nowhere. Carry the flag on the digest line so step 9 can check it.
Activity¶
act_currently_active, act_sessions_per_week, act_session_length,
act_types, act_daily_lifestyle, client_work_activity. All six — the
activity factor in step 3 is a judgement across them, not a lookup on one.
Goal¶
goal_primary is a checkbox, so it is a list and it will often contain goals
that pull in opposite directions — "Lose body fat" and "Build muscle"
together is the common case, not an edge case. Do not resolve it here. Record
the list, and let step 3
resolve it under its own rules.
Also goal_obstacles, goal_obstacles_plan, nut_support_wanted.
nut_support_wanted = "None, training only" is worth surfacing early: the
client has said they do not want this. Build it, and say in Notes for you that
it is there if wanted.
Current eating¶
nut_typical_day is the single most informative field in the questionnaire.
Read it properly — meal times, meal sizes, what is missing, what the client
notices about it. Then nut_typical_representative: where it is "No, better
than usual", the real baseline is worse than what is written and the menu is a
larger change than it looks.
From nut_ffq, extract only the standouts — anything "Daily" that the
menu will reduce, anything "Never" or "Occasionally" that the menu will
require. A client eating legumes "Never" is the fact that shapes the
fibre ramp; the other 28 rows are
context.
Then nut_meals_per_day, nut_first_meal, nut_last_meal,
nut_weekend_differs, nut_water, nut_caffeine, nut_caffeine_latest,
nut_beverage_sugar, nut_sugary_drinks, health_alcohol_units and its
quantity fields.
Constraints¶
The block that does the most work in step 8.
nut_pattern (+ nut_pattern_other), nut_intolerances, health_allergies,
nut_dislikes, nut_medical_diet, nut_eating_limitation,
nut_cooking_confidence, nut_who_cooks, nut_who_shops, nut_meals_out,
nut_household_eating, pref_budget, pref_accessibility.
Copy free-text fields whole. nut_dislikes = "I don't eat fish except tuna,
and no coriander" loses its exception when compressed to "dislikes fish", and
that lost exception is a wrong menu.
Symptoms¶
Every sys_digestive_* that is "Yes", plus sys_bowel_frequency,
sys_bowel_empty, sys_laxatives, life_energy_crash, life_energy_pattern,
life_sleep_hours, life_sleep_quality, life_stress_level,
life_shift_work (+ life_shift_pattern), life_travel.
Skip the "No" answers. Eleven digestive fields at "No" is one word: none.
Gaps¶
Every field above that was absent. Not a footnote — the list that determines which assumptions get made and which get printed.
Do not¶
- Do not interpret. The digest records what was said. It does not conclude that a client "probably" trains more than they wrote.
- Do not fill a gap. A missing
act_sessions_per_weekgoes in Gaps. Step 3 has a documented fallback; this step does not get to pre-empt it. - Do not drop a free-text field because it looks like noise. The exception that ruins a menu is nearly always in free text.
- Do not resolve contradictions.
act_currently_active="No"alongsideact_sessions_per_week= 4 gets recorded as the contradiction it is. Step 3 resolves it by taking the more conservative reading.
Next: 2. Safety screen