From aba03fd72df5729a86d21c6866761b43a8abad68 Mon Sep 17 00:00:00 2001 From: Tyler Hoang Date: Sat, 9 May 2026 01:26:06 -0700 Subject: Remove expiry and quantity from AI context and prompts - Strip quantity, unit, and expiry from pantry data sent to AI (name + category only) - Remove "prioritize expiring soon" guideline from menu generation prompt - Remove EXPIRING SOON section from pantry-only grocery prompt - SYSTEM_PROMPT in .env (gitignored) updated to drop expiry/quantity priorities Co-Authored-By: Claude Sonnet 4.6 --- services/ai_service.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'services/ai_service.py') diff --git a/services/ai_service.py b/services/ai_service.py index 0abad09..f128b4a 100644 --- a/services/ai_service.py +++ b/services/ai_service.py @@ -37,7 +37,7 @@ PANTRY STATE: GUIDELINES: - Suggest genuinely good, practical dishes — do NOT limit yourself to only pantry ingredients -- Prioritize using ingredients expiring soon (see expiring_soon), but feel free to include recipes that require buying additional items +- Use pantry ingredients where it makes sense, but freely include recipes that require buying additional items - Avoid meals eaten in the last 7 days (see recent_meals) - Include a mix of breakfast, lunch, and dinner options - Keep each recipe under 60 minutes @@ -121,9 +121,6 @@ async def generate_grocery_list_from_pantry(pantry_context: dict, user_notes: st CURRENT PANTRY: {json.dumps(pantry_context["available_ingredients"], indent=2)} -EXPIRING SOON: -{json.dumps(pantry_context.get("expiring_soon", []), indent=2)} - RULES: - Suggest ingredients that would complement what's already in the pantry - Group items by store section (produce, dairy, protein, pantry, frozen, bakery) -- cgit v1.3-2-g0d8e