Skip to content

feat(data): real amounts for catalog recipes rcp-000377..rcp-000934 - #195

Merged
SamGu-NRX merged 2 commits into
alphafrom
obv/burst11-fridgeluck-recipe-amounts-b
Oct 16, 2026
Merged

SamGu-NRX merged 2 commits into
alphafrom
obv/burst11-fridgeluck-recipe-amounts-b

Conversation

@obvious-autobuild

Copy link
Copy Markdown

What changed and why

The recipe catalog carries 106 non-staple ingredient lines with unknown quantities in rcp-000377..rcp-000934 (85 recipes). Unknown-quantity lines render "to taste" in the app and are excluded from nutrition math, so recipes in this band showed incomplete ingredient amounts and understated per-serving nutrition. This packet replaces each affected corpus record with one that quantifies every substantive line and keeps only genuinely taste-adjusted lines unknown.

Files (all new, no existing file modified):

  • data/recipes/fixes/amounts-b.json — the fix file (schema fridgeluck/corpus-fixes/v1, packet burst11-fridgeluck-recipe-amounts-b, base commit ef236fcd): 85 fixes, each pinning the base record's before_sha256 and documenting its changes. Of the 106 band lines, 69 get real amounts (source_grams or a pinned household conversion) and 37 stay unknown with an explicit to-taste note (chiles, finishing herbs, garnishes, salt/pepper).
  • data/recipes/fixes/test_amounts_b.py — 15 tests: band coverage is exact, before_sha256 matches the base corpus, titles and ingredient names (the rights-pin inputs) are unchanged, household refs resolve, recompiled records pass the compiler/validator checks, nutrition bars hold, and validate_corpus.py exits 0 over the patched corpus.
  • evaluation/recipe-quality/amounts_b.py — reproduces the band definition from the shipped bundle, compiles before/after nutrition per recipe, and writes the report.
  • evaluation/recipe-quality/amounts-b.md — the per-recipe before/after nutrition report (85 rows).

Method: amount anything a cook would weigh or measure to make the dish (proteins, starches, sauce bases, binders, structural produce); leave heat (chiles), finishing herbs, garnishes, and salt-and-pepper "to taste" with a note saying why. Household rows reuse the 129 existing pinned conversion references — no new conversion rows. Exceptions are explained in the fix's changes text: the ackee-and-saltfish sodium stays high because the dish is built on salt cod (the steps soak and boil it to draw off salt), and the duck-ragu / short-rib recipes sit above the kcal bar because a braise serving carries 200+ g of bone-in meat; the salt-pork red beans and rice quantifies the pork at the classic 150 g soffritto portion for 6 servings.

How I checked it

Commands and results (Linux sandbox, CPython 3.12):

  • python3 -m pytest data/recipes/fixes/test_amounts_b.py -q — 15 passed. Includes: fix file covers exactly the 85-recipe band; every before_sha256 matches the base corpus line; titles/ingredient names byte-identical; all 106 band lines quantified or explicitly to-taste; household grams equal value × pinned row mass; recompiled records pass vocabulary keys, claim-vs-composition, Atwater, sodium ceiling, timer rule, and thermometer-check placement; kcal 150–1300 and sodium ≤ 2300 mg per serving for all recipes without an explained exception (one initially over-bar recipe was re-portioned to one drained 280 g jar of roasted peppers and re-verified); validate_corpus.py exit 0 over the patched corpus; committed report matches a fresh render.
  • python3 -m pytest data/recipes/tools/tests -q — 38 passed, 1 skipped (same as base).
  • python3 data/recipes/tools/validate_corpus.py — VALIDATION GREEN on the working tree (rights-clear, claims verified, ids unique, no quarantined recipe; resolved_pct rises on the patched corpus).
  • python3 evaluation/recipe-quality/amounts_b.py — report regenerated; per-recipe kcal and sodium inside bars except the three documented exceptions.

What I couldn't check

  • No Xcode/macOS here: the shipped Swift bundle is not rebuilt in this PR. If a bundle rebuild is required before merge, PR feat(data): repair catalog identity pins and aliases for pantry reach #192's pipeline (which owns bundle/vocabulary files) is the place; this PR deliberately touches no bundle or vocabulary files. Amounts land in the app when the corpus fixes are compiled into a shipped bundle.
  • FNDDS-derived grams in pre-existing household rows are trusted as pinned (not re-measured); my fixes reuse those rows as-is.
  • Nutrient math is catalog per-100 g rows × line grams ÷ servings — a portion estimate, not a lab analysis.

What I assumed

  • The band definition (recipes with a non-staple unknown-quantity line, rcp-000377..rcp-000934, 85 recipes / 106 lines) is reproduced from the shipped bundle in evaluation/recipe-quality/amounts_b.py and pinned by test.
  • Portion choices are recipe-developer judgment grounded in the steps' own cues (pot/pans, servings, drained-jar weights, classic proportions); each fix's changes field records the basis. Where the catalog's per-100 g row made a generous portion blow the kcal bar, I sized the portion to the dish's serving count.
  • "To taste" remains correct only for lines whose amount genuinely has no canonical answer (heat, herbs, garnish, seasoning); every kept-unknown line's note says so.
  • No rights pins invalidated: source_ref and ingredient names untouched, no changes_rights_pin used.
  • Conventional-commits title feat(data); base branch alpha; draft PR, not merged.

ObviousApp and others added 2 commits October 16, 2026 07:36
Packet burst11-fridgeluck-recipe-amounts-b (base alpha ef236fc):

- data/recipes/fixes/amounts-b.json: 85 fixes covering all 106
  non-staple unknown-quantity lines in the band; 37 lines stay
  to-taste with notes, 69 get real amounts
- evaluation/recipe-quality/amounts_b.py: band reproduction,
  before/after nutrition, exception markers, report writer
- evaluation/recipe-quality/amounts-b.md: per-recipe report
- data/recipes/fixes/test_amounts_b.py: 15 tests pinning the fix
  file, the recompiled records, the nutrition bars, and the
  validate_corpus gates over the patched corpus
Co-authored-by: obvious-autobuild[bot] <262744130+obvious-autobuild[bot]@users.noreply.github.com>
@coderabbitai

coderabbitai Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 862d10eb-2cd1-49bc-a399-ea3ed2891bdc

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codemetrics-ai

Copy link
Copy Markdown

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.

@SamGu-NRX
SamGu-NRX merged commit 875f6d6 into alpha Oct 16, 2026
3 checks passed
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-16T12:26:14.940270Z 6e834ba Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants