Get ML Recommendation
Recommendations
Get ML Recommendation
POST
Get ML Recommendation
How Recommendations Work
SmartEat AI uses a machine learning model to provide personalized recipe recommendations. The system uses:- K-Nearest Neighbors (KNN) algorithm for similarity matching
- Nutritional profile matching based on calories, protein, carbs, and fat
- Diet type filtering (vegan, vegetarian, high-protein, low-carb, etc.)
- Meal type compatibility (breakfast, lunch, dinner, snack)
- User preference learning from your profile tastes and restrictions
Recommendation Features
1. Smart Meal Plan Generation
When you request a meal plan through the chat interface, the AI:- Analyzes your profile (goals, macros, preferences)
- Selects recipes that match your nutritional targets
- Ensures variety across the week
- Respects your dietary restrictions and preferences
- Balances meal types according to your meals-per-day setting
2. Recipe Similarity Matching
The ML model finds similar recipes based on:Calculates distance in a scaled feature space of calories, protein, carbohydrates, and fat content
Ensures recommended recipes match your selected diet types (e.g., vegan, high-protein)
Only recommends recipes suitable for the target meal slot (breakfast, lunch, dinner, snack)
Prevents recommending recipes already in your current meal plan
Getting Recommendations
You can get personalized recommendations through:Via Chat Interface
Request via Chat
Via Swap Endpoint
For direct recipe swapping, use the Swap Meal Recommendation endpoint.ML Model Architecture
Feature Space
The recommendation engine operates in a scaled feature space:Feature Scaling
Similarity Calculation
K-Nearest Neighbors
Example Recommendation Flow
Response Schema (Conceptual)
If this endpoint were implemented, it would return:Array of recommended recipes
Notes
- The ML model is loaded on application startup for fast inference
- Recommendations are personalized based on your complete profile
- The system learns from your preferences over time
- Use the Swap Meal endpoint for direct recipe substitutions
