Menu-Sahayak:即時提供印度餐廳餐牌致敏原資訊(由 Llama 3.3 驅動)
Menu-Sahayak: Instant Allergen Insights for Indian Restaurant Menus (Powered by Llama 3.3)
Menu-Sahayak 以 Llama 3.3 70B(開放權重)及 Groq 推理 API 分析印度餐廳餐牌,標示每道菜可能含有的致敏原。結果涵蓋乳製品、堅果、麩質、雞蛋及大豆,並附簡短安全提示;嚴重過敏者應向餐廳職員核實。
Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle Submission 💸
This is a submission for the Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle
What I Built
Menu-Sahayak is a lightweight web app that analyzes Indian restaurant menus and flags likely allergens per dish.
Tourists with food allergies often struggle to read Hindi or regional-language menus. Generic translation tools will tell you what "Chole Bhature" means, but they won't tell you it contains gluten and dairy. Menu-Sahayak bridges that gap. Paste a menu, and instantly get dish names alongside clear allergen tags (dairy, nuts, gluten, eggs, soy) and a practical safety note for each item.
It solves a very real, high-stakes problem for travelers and locals alike, making dining out safer and stress-free.
Demo
Here is a quick look at the interface:
(Apna screenshot yahan upload karein — DEV editor mein image icon par click karke)
Code
Allergen Lens — Menu Allergen Checker for Indian Restaurants
A lightweight Gradio app that analyzes Indian restaurant menu items and flags likely allergens per dish.
Powered by Llama 3.3 70B (open-weight) via Groq.
What it does
Paste menu items (one dish per line), and the app returns a numbered list with:
- dish name
- likely allergens from: dairy, nuts, gluten, eggs, soy
- one concise safety note
The model is instructed to avoid unsupported certainty: allergens are marked as likely/possible based on common preparation, and users should verify with restaurant staff for severe allergies.
Why this is useful
Tourists with allergies may struggle to read Hindi or regional-language menus. This tool provides quick, practical allergen guidance dish-by-dish.
Setup
- Clone this repository.
- Install dependencies:
pip install -r menu-sahayak/requirements.txt
- Create env file:
cp menu-sahayak/.env.example menu-sahayak/.env
- Add your Groq API key in
menu-sahayak/.env:GROQ_API_KEY=your_key_here
- Run:
cd menu-sahayak python app.py
Get a free Groq…
How I Built It
- Model: Llama 3.3 70B (open-weight) served via Groq's fast inference API.
- Frontend/UI: Python + Gradio (customized theme for a clean, mobile-friendly dashboard feel).
- The Core Logic: The app streams the response from the model and uses a highly specific system prompt to force the model into an "Allergen Analyst" persona. Instead of creative writing, it outputs structured, numbered allergen lists.
- Error Handling: Built-in graceful fallbacks for missing API keys, rate limits, and empty inputs.
Why Does Open Innovation Matter?
I chose Llama 3.3 70B (open-weight) over a closed API because:
- Cost-Effective for a Side Hustle: Groq's generous free tier makes this app ₹0 to run. A closed model with similar reasoning capabilities would charge per token, eating into the thin margins of a side project.
- Model Swap Freedom: Because the logic is built around an open-weight model, I am not locked into one provider. If I want to swap Llama for Qwen or Gemma tomorrow to improve allergy detection, it's a one-line change.
- Transparency and Control: Open weights mean I know exactly what is processing the user's input. For an app dealing with health and dietary safety, this transparency is crucial.
The open pieces aren't just a buzzword here — the entire product is built around an accessible, open-weight model that I can control, prompt, and eventually self-host if needed.
Prize Categories
Overall Side Hustle Challenge Entry.
#devchallenge #hf26challenge #opensource #ai #llama #python #sidehustle
來源:DEV Community · dev.to
