Repository navigation
feat(data): real amounts for catalog recipes rcp-000167..rcp-000376 (packet A) - #196
Conversation
86 band recipes carry 118 non-staple unknown-quantity lines: 103 measured with real amounts and 15 left to taste (seasoning, garnish, heat only), each with a note naming why. Three titles promising molasses gain a measured molasses line plus the step that uses it (rights-pinned). Fix file data/recipes/fixes/amounts-a.json (fridgeluck/corpus-fixes/v1) pins before_sha256 per record and carries per-line reason/evidence. The report evaluation/recipe-quality/amounts-a.md compiles before/after with the shipped compiler; six recipes land outside the 150-1300 kcal / 2300 mg sodium bars with the exceedance explained in their changes entries. Tests: pytest evaluation/recipe-quality/test_amounts_a.py (12 passed). Co-authored-by: Sam Gu <sgu07966@gmail.com>
|
Important Review skippedBot user detected. To trigger a single review, invoke the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Note Review skipped Codemetrics is installed on this repository, but it hasn't been added to your team yet. To enable AI code reviews for this repo, go to your dashboard and add FridgeLuck to your team's repositories. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
What changed and why
Band
rcp-000167–rcp-000376of the shipped catalog (recipes-v2.json) carries 118 non-staple ingredient lines whose quantity is unknown across 86 recipes — lines the cook reads as "add the chicken" with no amount, so the app's nutrition math silently skips them. This PR is the review packet that fixes them at the corpus source:data/recipes/fixes/amounts-a.json, schemafridgeluck/corpus-fixes/v1.Every one of the 118 lines gets exactly one decision:
source_gramsor ahouseholdunit the compiler's conversion table supports), reasoned in the line'schangesentry — e.g. the protein of the dish scales ~100–150 g/serving, pasta 70–85 g dry/serving, a title-named component gets a cook's portion.Three titles promise molasses but the record has no molasses line ("Molasses-Glazed…" etc.): those three recipes gain one measured molasses line each plus the step sentence that uses it. These are flagged
changes_rights_pin: true(original-claimed recipes gaining new content). No other record field changes — titles, servings, rights, composition, allergens, and every other step are byte-identical (test-enforced).The report (
evaluation/recipe-quality/amounts-a.md) compiles before/after with the shipped compiler (compile_bundle.compile_recipe) — before reproduces the bundle's shipped numbers exactly, confirming the packet's baseline is the app's own math. Six recipes land outside the 150–1300 kcal / 2300 mg sodium per-serving bars; each carries the marker and a worked explanation in itschangesevidence (e.g.rcp-000247dates bowl: base is already 1525.9 kcal and the measured dates add 62;rcp-000351minestrone: committed stock/salt/canned lines are 2036.7 mg before the sausage lands, and a true 100 g/serving sausage portion adds ~773 — trimming the protein to fit the bar would not be a cook's amount).The generator (
evaluation/recipe-quality/amounts_a.py) and the pytest validation (test_amounts_a.py) are committed so the packet is reproducible and reviewable line by line.How I checked it
pytest evaluation/recipe-quality/test_amounts_a.py -v— 12 passed: fix-file shape and per-recordbefore_sha256pins match the corpus; fix set equals the independently reconstructed band (86 recipes/118 lines); every band line measured-or-noted; to-taste set equals the closed 15; only owned paths change; the three name additions are exactly molasses with the step edit; before-compile reproduces shipped bundle nutrition (all 86); after-compile within bars except the six explained cases; explained values match compiled values; report table agrees with compiled numbers.python3 data/recipes/tools/validate_corpus.py— VALIDATION GREEN (rights-clear, claims verified, ids in-scheme) on the untouched corpus.python3 data/recipes/tools/validate_bundle.py apps/ios/Resources/RecipeCatalog/recipes-v2.json— PASS on the untouched bundle.before_sha256match corpus lines, no duplicate change paths within a recipe, exactly six exceedance markers.cmpagainstgit show HEAD:<path>for all four files).What I could not check
recipes-v2.json— this PR is the fix packet for review, not the bundle bump; applying it to the corpus/bundle is the follow-up step and its compile/CI evidence comes then.preserved lemonis absent from the vocabulary (counted as 0 kcal/sodium); noted in the recipe's evidence.Assumptions
alpha, draft, mirroring the sibling packet PR feat(data): real amounts for catalog recipes rcp-000377..rcp-000934 #195 (rcp-000377–rcp-000934), so the two amounts packets review together.conversions.json) maps them; grams otherwise. "Developer sizing" lines cite the per-serving reasoning.fl-original-NNNN↔rcp-…), verified againstcatalog_idin the bundle.Human author: Sam Gu (sgu07966@gmail.com)
🔗 Obvious Project · 🧵 Obvious Thread · 🔀 Obvious PR Artifact