{"skills":[{"name":"Resize a recipe for portions and equipment","description":"Scale ingredients for a target number of portions, preserve non-linear cooking instructions and split work across the equipment available.","content":"# Resize a recipe for portions and equipment\n\nScale ingredients for a target number of portions, preserve non-linear cooking instructions and split work across the equipment available.\n\n## When to use this skill\n\n- A recipe serves 4 and the person needs it for 12, or for 2.\n- A caterer needs smaller or larger portions than the recipe gives, such as 30 buffet portions of 100 g.\n- Someone needs to know how many pans, trays or mixer loads the scaled recipe will take.\n- A share of the finished batch has to be held back for tasting, staff meals or the freezer.\n\n## When not to use it\n\n- Bread doughs. Use the baker's percentage skill, which keeps hydration and salt in proportion to flour.\n- Changing a cake's tin size. Use the cake tin skill, which also checks depth.\n- Converting cups to grams. Convert first with the cup conversion skill, then scale.\n\n## What you need\n\n- Original recipe yield, ingredient quantities and portion size plus the target number and size of portions.\n- Pan or mixer working capacity, indivisible or taste-adjusted ingredients and the original cooking instructions.\n\n## Ask before you start\n\nIf any of these are missing or unclear, ask before doing the work.\n\n- How many portions does the original recipe make, and how big is each? 'Serves 4' needs a portion weight or volume when the new portions are a different size.\n- How many portions are needed, of what size, and should any of the finished batch be held back?\n- What is the working capacity of the pan, tray, oven or mixer, in portions or weight?\n- Are any ingredients 'to taste', whole items like eggs, or seasonings you would rather adjust by tasting?\n\n## Method\n\n1. Express both yields as a total. If the portion sizes match, use the counts. If they differ, multiply count by portion size for each (10 \u00d7 150 g is 1.5 kg; 30 \u00d7 100 g is 3 kg).\n2. Add any reserve. If a share r of the finished batch is held back, the batch must be the plated yield \u00f7 (1 \u2212 r). If the reserve is an extra on top of the plated amount, multiply by (1 + r) instead. Use the one the person described.\n3. Factor = required total \u00f7 original total. Convert mixed units to one unit first, then multiply every numeric ingredient by the factor in its own unit.\n4. Keep 'to taste' and similar instructions as written. Keep fractional eggs as a fraction or a weight of beaten egg rather than rounding the whole recipe, and round other quantities only at the end to amounts that can be measured.\n5. Batches = scaled total \u00f7 working capacity, rounded up. Capacity stated in original portions means original-size portions. Split quantities evenly and check each batch fits. Leave the batch count open when capacity is unknown.\n6. Keep the original oven temperature and the recipe's doneness checks. Do not multiply cooking times by the factor, because time depends on the depth and size of each pan, not the total quantity.\n7. For a large or commercial run, make the first scaled batch and check its yield, seasoning and texture before committing the rest of the ingredients.\n\n## Checks before you deliver\n\n- Ten guests taking one-and-a-half servings each is a 15-serving requirement.\n- A mixer rated for ten portions cannot take an entire 25-portion dough merely because the ingredients scale.\n- Scaling by portion count when the portion size changes: 30 portions of 100 g from a recipe for 10 of 150 g is a factor of 2, not 3.\n- Adding 10% to the plated amount when 10% of the finished batch is to be held back: 2.7 L \u00d7 1.1 is 2.97 L, but 3 L is needed.\n- Multiplying the cooking time along with the ingredients.\n\n## How to present the result\n\nOpen with the factor and the plan ('Make the recipe twice over, in two batches at 180\u00b0C'). Then give the scaled ingredient list in the recipe's order and units, with per-batch quantities when there are several batches. Note anything kept as written and any fraction to weigh, and end with the doneness reminder.\n\n## Worked example\n\n**Request:** Resize this bake for a buffet.\n\n**Supplied material:**\n\n```text\nMakes 10 portions weighing 150 g each. Want 30 portions of 100 g each. Flour 500 g, eggs 3, parsley to taste. Oven 180 C. Pan holds 10 original-size portions.\n```\n\n**Answer:** Make two batches at 180\u00b0C. For each, use 500 g flour, 3 eggs and parsley to taste. Together they give the 3 kg needed for thirty 100 g buffet portions.\n\n## Structured output for tests\n\nFor an ordinary job, answer in the format above and point back to the supplied evidence. Use this structure only for the test cases published with this skill, or when someone asks for structured JSON.\n\nReturn factor, ingredients keyed by the exact input ingredient names (numeric quantities in original units, or the original nonnumeric instruction), batches (minimum integer, or null when working capacity is unknown), and oven_c (original value, or null if unused). Round numeric quantities to three decimals only for display. Treat capacity stated in original portions as original-size portions.\n\n## Sources\n\n- [Institute of Child Nutrition: adjusting standardised recipes](https:\/\/theicn.org\/cacfp-itrain-simple-lesson-plans\/training-scripts\/Adjusting-Standardized-Recipes.pdf): The lesson finds the multiplying factor as servings needed \u00f7 the recipe's servings, multiplies each ingredient by it, converts mixed units to a common unit first, and its sample recipe scales the number of pans with the servings (one pan for 25, two for 50).\n- [Institute of Child Nutrition: Basic Culinary Math participant's workbook](https:\/\/theicn.org\/resources\/118\/basic-culinary-math-for-school-nutrition-professionals\/106918\/basic-culinary-math-participants-workbook.pdf): Lessons II and III cover measurement conversions and the scaling factor method for increasing and decreasing a standardised recipe's yield, including converting both weights to the same unit before multiplying.\n\nTest cases and an answer checker for this skill: https:\/\/skills.raq.com\/skills\/resize-a-recipe-batch\n","scope":"contextual","trigger_keywords":["Resize a recipe for portions and equipment","resize-a-recipe-batch","resize a recipe batch","This recipe serves 4. How do I make it for 12?","This recipe serves 4. How do I make it for 12","scale this recipe","resize this recipe","recipe for more servings"],"is_private":true,"is_active":true,"scripts":[{"name":"resize-a-recipe-batch-check","description":"Compare a saved JSON answer with a published test. Pass tests\/case-1\/expected.json (or another case) and the path to your answer.","language":"python","filename":"resize-a-recipe-batch-check.py","content":"from pathlib import Path\nimport runpy\n\nrunpy.run_path(str(Path(__file__).parent \/ 'tests' \/ 'check.py'), run_name='__main__')\n","supporting_files":[{"path":"SKILL.md","content":"---\nname: resize-a-recipe-batch\ndescription: \"Scale a recipe to a new number or size of portions, keep non-numeric and indivisible quantities sensible, and split the work into batches that fit the pan, tray or mixer. Use when someone asks to scale a recipe up or down, cook for more people, change portion sizes or fit a large batch into their equipment.\"\nlicense: CC-BY-4.0\nmetadata:\n  author: Raq.com\n  version: \"2026-11-22\"\n  homepage: https:\/\/skills.raq.com\/skills\/resize-a-recipe-batch\n---\n\n# Resize a recipe for portions and equipment\n\nScale ingredients for a target number of portions, preserve non-linear cooking instructions and split work across the equipment available.\n\n## When to use this skill\n\n- A recipe serves 4 and the person needs it for 12, or for 2.\n- A caterer needs smaller or larger portions than the recipe gives, such as 30 buffet portions of 100 g.\n- Someone needs to know how many pans, trays or mixer loads the scaled recipe will take.\n- A share of the finished batch has to be held back for tasting, staff meals or the freezer.\n\n## When not to use it\n\n- Bread doughs. Use the baker's percentage skill, which keeps hydration and salt in proportion to flour.\n- Changing a cake's tin size. Use the cake tin skill, which also checks depth.\n- Converting cups to grams. Convert first with the cup conversion skill, then scale.\n\n## What you need\n\n- Original recipe yield, ingredient quantities and portion size plus the target number and size of portions.\n- Pan or mixer working capacity, indivisible or taste-adjusted ingredients and the original cooking instructions.\n\n## Ask before you start\n\nIf any of these are missing or unclear, ask before doing the work.\n\n- How many portions does the original recipe make, and how big is each? 'Serves 4' needs a portion weight or volume when the new portions are a different size.\n- How many portions are needed, of what size, and should any of the finished batch be held back?\n- What is the working capacity of the pan, tray, oven or mixer, in portions or weight?\n- Are any ingredients 'to taste', whole items like eggs, or seasonings you would rather adjust by tasting?\n\n## Method\n\n1. Express both yields as a total. If the portion sizes match, use the counts. If they differ, multiply count by portion size for each (10 \u00d7 150 g is 1.5 kg; 30 \u00d7 100 g is 3 kg).\n2. Add any reserve. If a share r of the finished batch is held back, the batch must be the plated yield \u00f7 (1 \u2212 r). If the reserve is an extra on top of the plated amount, multiply by (1 + r) instead. Use the one the person described.\n3. Factor = required total \u00f7 original total. Convert mixed units to one unit first, then multiply every numeric ingredient by the factor in its own unit.\n4. Keep 'to taste' and similar instructions as written. Keep fractional eggs as a fraction or a weight of beaten egg rather than rounding the whole recipe, and round other quantities only at the end to amounts that can be measured.\n5. Batches = scaled total \u00f7 working capacity, rounded up. Capacity stated in original portions means original-size portions. Split quantities evenly and check each batch fits. Leave the batch count open when capacity is unknown.\n6. Keep the original oven temperature and the recipe's doneness checks. Do not multiply cooking times by the factor, because time depends on the depth and size of each pan, not the total quantity.\n7. For a large or commercial run, make the first scaled batch and check its yield, seasoning and texture before committing the rest of the ingredients.\n\n## Checks before you deliver\n\n- Ten guests taking one-and-a-half servings each is a 15-serving requirement.\n- A mixer rated for ten portions cannot take an entire 25-portion dough merely because the ingredients scale.\n- Scaling by portion count when the portion size changes: 30 portions of 100 g from a recipe for 10 of 150 g is a factor of 2, not 3.\n- Adding 10% to the plated amount when 10% of the finished batch is to be held back: 2.7 L \u00d7 1.1 is 2.97 L, but 3 L is needed.\n- Multiplying the cooking time along with the ingredients.\n\n## How to present the result\n\nOpen with the factor and the plan ('Make the recipe twice over, in two batches at 180\u00b0C'). Then give the scaled ingredient list in the recipe's order and units, with per-batch quantities when there are several batches. Note anything kept as written and any fraction to weigh, and end with the doneness reminder.\n\n## Worked example\n\n**Request:** Resize this bake for a buffet.\n\n**Supplied material:**\n\n```text\nMakes 10 portions weighing 150 g each. Want 30 portions of 100 g each. Flour 500 g, eggs 3, parsley to taste. Oven 180 C. Pan holds 10 original-size portions.\n```\n\n**Answer:** Make two batches at 180\u00b0C. For each, use 500 g flour, 3 eggs and parsley to taste. Together they give the 3 kg needed for thirty 100 g buffet portions.\n\n## Structured output for tests\n\nFor an ordinary job, answer in the format above and point back to the supplied evidence. Use this structure only for the test cases published with this skill, or when someone asks for structured JSON.\n\nReturn factor, ingredients keyed by the exact input ingredient names (numeric quantities in original units, or the original nonnumeric instruction), batches (minimum integer, or null when working capacity is unknown), and oven_c (original value, or null if unused). Round numeric quantities to three decimals only for display. Treat capacity stated in original portions as original-size portions.\n\n## Sources\n\n- [Institute of Child Nutrition: adjusting standardised recipes](https:\/\/theicn.org\/cacfp-itrain-simple-lesson-plans\/training-scripts\/Adjusting-Standardized-Recipes.pdf): The lesson finds the multiplying factor as servings needed \u00f7 the recipe's servings, multiplies each ingredient by it, converts mixed units to a common unit first, and its sample recipe scales the number of pans with the servings (one pan for 25, two for 50).\n- [Institute of Child Nutrition: Basic Culinary Math participant's workbook](https:\/\/theicn.org\/resources\/118\/basic-culinary-math-for-school-nutrition-professionals\/106918\/basic-culinary-math-participants-workbook.pdf): Lessons II and III cover measurement conversions and the scaling factor method for increasing and decreasing a standardised recipe's yield, including converting both weights to the same unit before multiplying.\n\nTest cases and an answer checker for this skill: https:\/\/skills.raq.com\/skills\/resize-a-recipe-batch\n"},{"path":"LICENSE.txt","content":"Original Raq.com instructions and synthetic examples: CC BY 4.0.\nhttps:\/\/creativecommons.org\/licenses\/by\/4.0\/\nAttribution: Raq.com, https:\/\/skills.raq.com\/skills\/resize-a-recipe-batch\nReferenced third-party materials retain their own terms.\n"},{"path":"examples\/worked-example.md","content":"# Thirty smaller portions\n\nResize this bake for a buffet.\n\n## Supplied material\n\nMakes 10 portions weighing 150 g each. Want 30 portions of 100 g each. Flour 500 g, eggs 3, parsley to taste. Oven 180 C. Pan holds 10 original-size portions.\n\n## Worked answer\n\nMake two batches at 180\u00b0C. For each, use 500 g flour, 3 eggs and parsley to taste. Together they give the 3 kg needed for thirty 100 g buffet portions.\n\n## Reasoning\n\nThe buffet needs twice the food, even though it has three times as many portions.\n"},{"path":"tests\/check.py","content":"\"\"\"Check a saved agent answer locally with Python 3 (standard library only).\"\"\"\nimport json\nimport math\nimport sys\nfrom pathlib import Path\n\n\ndef compare(expected, actual, path=\"$\", accepted=None):\n    if isinstance(expected, bool) or isinstance(actual, bool):\n        if expected is not actual:\n            yield path\n    elif isinstance(expected, (int, float)) and isinstance(actual, (int, float)):\n        if not math.isclose(expected, actual, rel_tol=0, abs_tol=1e-8):\n            yield path\n    elif isinstance(expected, dict) and isinstance(actual, dict):\n        for key in sorted(set(expected) | set(actual)):\n            if key not in expected or key not in actual:\n                yield f\"{path}.{key}\"\n            elif not any(\n                not list(compare(option, actual[key]))\n                for option in (accepted or {}).get(key, [])\n            ):\n                yield from compare(expected[key], actual[key], f\"{path}.{key}\")\n    elif isinstance(expected, list) and isinstance(actual, list):\n        if len(expected) != len(actual):\n            yield f\"{path} (length)\"\n        for i, (left, right) in enumerate(zip(expected, actual)):\n            yield from compare(left, right, f\"{path}[{i}]\")\n    elif type(expected) != type(actual) or expected != actual:\n        yield path\n\n\ndef main():\n    if len(sys.argv) != 3:\n        raise SystemExit(\"Usage: python3 check.py expected.json answer.json\")\n    try:\n        expected, actual = [json.loads(Path(p).read_text(encoding=\"utf-8\")) for p in sys.argv[1:]]\n        alternatives = Path(sys.argv[1]).with_name(\"accepted.json\")\n        accepted = json.loads(alternatives.read_text(encoding=\"utf-8\")) if alternatives.is_file() else {}\n    except (ValueError, OSError) as error:\n        raise SystemExit(str(error))\n    differences = list(compare(expected, actual, accepted=accepted))\n    if differences:\n        raise SystemExit(\"Different fields: \" + \", \".join(differences))\n    print(\"Pass\")\n\n\nif __name__ == \"__main__\":\n    main()\n"},{"path":"tests\/README.md","content":"Give your agent SKILL.md and one request.txt in a fresh session. Keep the expected answer aside. Save the reply as answer.json, then run this from the tests folder:\n\n    python3 check.py case-1\/expected.json answer.json\n\nEach case also has an explanation. Where accepted.json exists, the checker accepts the alternatives listed there.\n"},{"path":"tests\/case-1\/request.txt","content":"Resize this bake for a buffet.\nReturn only the JSON specified in SKILL.md for this test.\n\nMakes 10 portions weighing 150 g each. Want 30 portions of 100 g each. Flour 500 g, eggs 3, parsley to taste. Oven 180 C. Pan holds 10 original-size portions.\n"},{"path":"tests\/case-1\/expected.json","content":"{\n    \"factor\": 2,\n    \"ingredients\": {\n        \"Flour\": 1000,\n        \"eggs\": 6,\n        \"parsley\": \"to taste\"\n    },\n    \"batches\": 2,\n    \"oven_c\": 180\n}\n"},{"path":"tests\/case-1\/explanation.txt","content":"The buffet needs twice the food, even though it has three times as many portions.\n"},{"path":"tests\/case-2\/request.txt","content":"Scale without rounding the egg count.\nReturn only the JSON specified in SKILL.md for this test.\n\nRecipe makes 8 equal rolls. Need 3 same-size rolls. Flour 400 g, eggs 2. One tray holds all 8. Oven 200 C.\n"},{"path":"tests\/case-2\/expected.json","content":"{\n    \"factor\": 0.375,\n    \"ingredients\": {\n        \"Flour\": 150,\n        \"eggs\": 0.75\n    },\n    \"batches\": 1,\n    \"oven_c\": 200\n}\n"},{"path":"tests\/case-2\/explanation.txt","content":"The mathematical quantity is three quarters of an egg, which can be measured from beaten egg.\n"},{"path":"tests\/case-3\/request.txt","content":"Scale the stock for nine bowls and the reserve.\nReturn only the JSON specified in SKILL.md for this test.\n\nOriginal finished yield 2 L from 1.2 L stock. Serve nine 300 mL bowls. Hold back 10% of the finished soup. No oven; pan working capacity unreported.\n"},{"path":"tests\/case-3\/expected.json","content":"{\n    \"factor\": 1.5,\n    \"ingredients\": {\n        \"stock\": 1.8\n    },\n    \"batches\": null,\n    \"oven_c\": null\n}\n"},{"path":"tests\/case-3\/explanation.txt","content":"The bowls take 90% of a 3 L batch. Adding only 10% to the served quantity would leave the reserve short.\n"}],"is_active":true,"is_approved":false}]}]}