Search 322 Chinese recipes from HowToCook, track fridge inventory, and plan meals based on what's available. Supports recipe search, random picks, category browsing, and fridge-aware meal planning.
Search Chinese recipes, track fridge inventory, and plan meals. Recipe database from the HowToCook project (322 recipes, programmer-style with exact measurements).
All files are in this skill directory (/home/node/.claude/skills/cooking-planning/):
all_recipes.json — 322 recipes with structured fields (read-only, query with python3)fridge.md — template for fridge inventory (copy to workspace on first use)The fridge inventory lives at /workspace/group/fridge.md (persistent across restarts).
On first /cook fridge or /cook plan, check if /workspace/group/fridge.md exists. If not, copy the template:
cp /home/node/.claude/skills/cooking-planning/fridge.md /workspace/group/fridge.md
All reads and writes to fridge go to /workspace/group/fridge.md, NOT the skill directory copy.
IMPORTANT: all_recipes.json is 1.5 MB. NEVER read it directly or dump it into context. Always query with python3.
Each recipe in all_recipes.json has:
name — dish name (e.g. "辣椒炒肉的做法")category — one of: 荤菜(97), 素菜(54), 主食(47), 水产(24), 早餐(22), 饮品(21), 汤(21), 甜品(17), 半成品加工(10), 调料(9)difficulty — 1-5 starsingredients[] — each has name, quantity, unit, text_quantitysteps[] — each has order, contentdescription — full markdown recipe texttags[] — searchable tagsservings, prep_time, cook_timepython3 -c "
import json
with open('/home/node/.claude/skills/cooking-planning/all_recipes.json') as f:
recipes = json.load(f)
for r in recipes:
if 'KEYWORD' in r['name'] or any('KEYWORD' in i['name'] for i in r.get('ingredients', [])):
print(f\"{r['name']} | {r['category']} | 难度:{r['difficulty']} | 食材: {', '.join(i['name'] for i in r.get('ingredients', [])[:5])}\")"
python3 -c "
import json
with open('/home/node/.claude/skills/cooking-planning/all_recipes.json') as f:
recipes = json.load(f)
for r in recipes:
if r['category'] == 'CATEGORY':
print(f\"{r['name']} | 难度:{r['difficulty']}\")"
python3 -c "
import json
with open('/home/node/.claude/skills/cooking-planning/all_recipes.json') as f:
recipes = json.load(f)
for r in recipes:
if 'DISH_NAME' in r['name']:
print(r['description'])
break"
python3 -c "
import json, random
with open('/home/node/.claude/skills/cooking-planning/all_recipes.json') as f:
recipes = json.load(f)
r = random.choice(recipes)
print(f\"{r['name']} | {r['category']} | 难度:{r['difficulty']}\"
f\"\n食材: {', '.join(i['name'] for i in r.get('ingredients', [])[:8])}\")"
python3 -c "
import json
with open('/home/node/.claude/skills/cooking-planning/all_recipes.json') as f:
recipes = json.load(f)
# Replace this list with actual fridge contents
fridge = ['鸡蛋', '青椒', '西红柿', '五花肉', '豆腐']
results = []
for r in recipes:
ing_names = [i['name'] for i in r.get('ingredients', [])]
matches = sum(1 for f_item in fridge if any(f_item in ing for ing in ing_names))
if matches >= 2:
results.append((matches, r['name'], r['category'], r['difficulty'], ing_names[:6]))
results.sort(reverse=True)
for matches, name, cat, diff, ings in results[:10]:
print(f\"[{matches}个匹配] {name} | {cat} | 难度:{diff} | 食材: {', '.join(ings)}\")"
/cook <keyword> — Search for a recipedescription field)/cook category <name> — Browse a categoryValid categories: 荤菜, 素菜, 主食, 水产, 早餐, 饮品, 汤, 甜品, 半成品加工, 调料
/cook what — Random recipe suggestion/cook plan — Meal plan based on fridge/workspace/group/fridge.md for current inventory/cook fridge — Update fridge inventoryfridge.md and show summary to user/workspace/group/fridge.md with changes/cook fridge <items> — Quick add to fridge/workspace/group/fridge.mdWhen updating /workspace/group/fridge.md:
item quantity (optional expiry)