Recipe browser: domain/category navigation with pantry match badges (Free tier) #25
Labels
No labels
accessibility
backlog
beta-feedback
bug
duplicate
enhancement
feature-request
help wanted
invalid
needs-design
needs-triage
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Circuit-Forge/kiwi#25
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Browse the full recipe corpus by pre-baked domain schemas (cuisine, meal type, dietary, main ingredient), with pantry match percentage shown inline. Free tier.
Domain Schemas
New file:
app/services/recipe/browser_domains.pyFour domains, each mapping keyword sets to a two-level category hierarchy:
Matching is case-insensitive against the
categorycolumn andkeywordsJSON array already in therecipestable. A recipe may appear in multiple categories (correct).Before writing this module: run
SELECT category, count(*) FROM recipes GROUP BY category ORDER BY count(*) DESCagainst the food.com corpus to calibrate keyword mappings.Store Methods
get_browser_categories(domain: str) -> list[dict]—[{category, recipe_count}]browse_recipes(domain, category, page, page_size, pantry_items) -> dict—{recipes, total, page}, each recipe includesmatch_pct: float | Nonematch_pctis set intersection of pantry_items vsingredient_names— deterministic, no LLM (large language model) needed.API Endpoints
Extend
app/api/endpoints/recipes.py:GET /recipes/browse/domains— list domain schemasGET /recipes/browse/{domain}— categories with recipe countsGET /recipes/browse/{domain}/{category}?page=1&page_size=20&pantry_items=item1,item2Pantry Match Badges
Frontend pulls pantry items from the inventory store automatically (no extra user action). Badge thresholds:
Nesting Depth Telemetry
Migration 020:
browser_telemetrytable —(domain, category, page_reached, result_count, recorded_at). Log on each browse request. Review manually: if any category has page > 5 and result_count > 100 consistently, consider adding a third nesting level.Frontend
RecipeBrowserPanel.vue— domain pill picker, category list with count chips, recipe grid/list with pantry match badges, paginationRecipesView.vue(tab bar: Find / Browse / Saved)RecipeDetailPanelSpec
circuitforge-plans/kiwi/superpowers/specs/2026-04-07-saved-recipes-browser-design.mdsection 4