Inspiration
When one of our team members, Valens, first arrived at Tufts University, he ran into a surprisingly frustrating problem: he never knew what and where to eat. The dining website technically had all the information: calories, ingredients, dietary notes, but accessing it required clicking through multiple menus and reading long descriptions for each item. When you’re hungry, the last thing you want to do is manually scan dozens of dishes just to figure out what fits your needs. We realized that Valens was not the only one facing that problem. Many students were facing the same
What it does
Dfood Meal Planner helps students quickly decide what to eat and where to eat based on their personal needs. Students can enter A meal calorie target, their diet type(Vegan, Vegetarian, Keto, etc), allergies, and food preferences. The app uses Tufts’ public dining APIs to filter available meals and generate optimized meal combinations that fit those constraints. Instead of browsing multiple dining halls and manually calculating totals, students instantly receive personalized recommendations, including the best dining location to visit.
How we built it
We built the backend using Python and FastAPI. It connects to Tufts’ public dining API, which is updated every week, and pulls in the menu data for each dining hall and meal. Once we received the data, we cleaned it and organized it so things like calories, ingredients, and dietary labels were easy to work with. The raw data wasn’t always perfectly structured, so we had to make sure everything was consistent before using it. Then we built the filtering logic. This part checks: Does the meal stay within the user’s calorie goal? Does it match their diet type? Does it avoid their allergens? Does it include foods they prefer? For the frontend, we used Next.js to build a clean and responsive interface. The frontend sends requests to our FastAPI backend and displays the recommended meals in a simple, easy-to-read layout. We also used v0 AI to help design and improve the UI quickly. It helped us move faster on the visual side while we focused on making the filtering and logic work correctly behind the scenes.
Challenges we ran into
One of our biggest challenges was handling inconsistent or incomplete data from the public API. Ingredient naming and dietary labels required normalization to ensure accurate filtering. Another challenge was managing multiple constraints simultaneously. Generating meal combinations that satisfy calorie goals while also respecting allergens and diet types required careful backend logic. We also faced frontend-backend integration challenges, including handling CORS configuration and ensuring smooth API communication.
Accomplishments that we're proud of
- Successfully integrating a real-world public dining API
- Building a backend filtering and optimization system using FastAPI
- Designing a responsive frontend with Next.js
- Recommending both meal combinations and dining locations
- Creating a practical solution to a real student problem
What we learned
- We learned how to work with external public APIs and handle real-world data inconsistencies.
- We gained experience designing constraint-based filtering systems in a practical application.
- We also learned how powerful modern frameworks like FastAPI and Next.js are when combined, and how AI-assisted tools like v0 can accelerate UI development.
What's next for Dfood Meal Planner
- We plan to integrate real-time dining hall availability and hours.
- We want to expand our optimization logic to include macronutrient balancing (protein, carbs, fats).
- We also aim to add user accounts so students can save preferences and streamline future meal planning.
- Our long-term goal is to scale Dfood Meal Planner beyond Tufts and support dining systems at other universities.
Built With
- fastapi
- nextjs
- python
- railway
- tufts-public-api
- typescript
- v0
- vercel
Log in or sign up for Devpost to join the conversation.