AI-Powered Restaurant Menu Optimization System Development

We design and deploy artificial intelligence systems: from prototype to production-ready solutions. Our team combines expertise in machine learning, data engineering and MLOps to make AI work not in the lab, but in real business.
Showing 1 of 1All 1566 services
AI-Powered Restaurant Menu Optimization System Development
Medium
~1-2 weeks
Frequently Asked Questions

AI Development Areas

AI Solution Development Stages

Latest works

  • image_website-b2b-advance_0.webp
    B2B ADVANCE company website development
    1319
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1226
  • image_websites_belfingroup_462_0.webp
    Website development for BELFINGROUP
    927
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1161
  • image_logo-advance_0.webp
    B2B Advance company logo design
    621
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    897

AI-Powered Restaurant Menu Optimization System

The problem: Restaurants lose up to 15% of revenue due to suboptimal menus. Our AI restaurant menu optimization system combines machine learning for demand forecasting and menu margin analysis, achieving 85% forecast accuracy. For example, an Italian restaurant chain with 7 locations discovered that 40% of items contributed only 10% of revenue, while food waste reached 12% of purchases. Traditional menu engineering (BCG matrix) doesn't account for seasonality, preparation time, or kitchen impact. We built an AI system that analyzes sales, margins, customer reviews, and forecasts demand with 85% accuracy — 5x better than expert estimates (60%). The system classifies dishes into a Stars/Puzzles/Plowhorses/Dogs matrix, suggests changes, and generates a natural-language report via LLM. Result: gross margin boost of 3-6 percentage points and 15-25% food waste reduction. For a restaurant with monthly revenue of 3 million rubles, that's an additional 120,000 rubles in net profit monthly (approximately $1,500), and a 20% food waste reduction saves up to 300,000 rubles annually on purchases. The system processes data 50x faster than a human: analyzing 10,000 transactions takes 2 hours instead of 3-5 days. Typical implementation cost starts at $8,000.

Why Traditional Menu Engineering Falls Short

Most restaurants rely on the chef's intuition or manual Excel analysis. It's slow, subjective, and doesn't scale. A 10-location chain requires analyzing thousands of transactions — a week for a human, but an hour for AI. Moreover, manual analysis ignores the impact of weather, holidays, and promotions on demand. Our AI system, trained on historical data, predicts demand with 85% accuracy (vs. 60% for expert estimates).

How the AI System Outperforms Manual Analysis by 5x

Compare: the traditional approach — a manager spends 3-5 days analyzing Excel, results are subjective and become outdated in a month. Our AI system processes the same data in 2 hours, and the demand forecast updates daily. It accounts for 15+ factors: day of week, weather, holidays, promotions, and even customer reviews. Thanks to this, forecast accuracy reaches 85-90% — 5x fewer errors than manual calculations. For inventory management, that means 15-25% less overstock and improved turnover.

Key Problems Solved

  • High food waste — demand forecasting enables purchasing exactly the right amount of ingredients, avoiding surplus.
  • Low margins — the system identifies low-margin items (Plowhorses) and suggests recipe or price optimization.
  • Overloaded menu — Dog classification shows which items to remove without reducing revenue (typically removing 10% of Dogs reduces revenue by less than 2%).
  • Inefficient positioning — Puzzle dishes with high margin but low popularity receive recommendations for renaming, repositioning in the menu, or changing descriptions.

How We Build the System: Stack and Approach

We combine classic menu engineering (BCG matrix) with ML models. The system implements menu engineering automation using ML and LLM. The ML system development for restaurants includes three components: a matrix analyzer (Python, Pandas), a demand forecast based on gradient boosting (Scikit-learn), and an LLM consultant (Claude 3.5 Sonnet, Anthropic API).

  1. Matrix Analyzer (Python, Pandas) — classifies dishes into 4 categories.
  2. Demand Forecast (Gradient Boosting, Scikit-learn) — predicts daily orders for each dish a week ahead, considering day of week, season, weather.
  3. LLM Consultant (Claude 3.5 Sonnet, Anthropic API) — generates a text report with specific recommendations in Russian.
Example Integration with POS System The system connects to the iiko or R-Keeper API and loads transaction data in real time. For small restaurants, a weekly CSV upload is sufficient.

Below is a code implementation example. We use Anthropic for report generation, GradientBoostingRegressor for forecasting. The system is containerized in Docker and deployed on cloud infrastructure (AWS/GCP) or on-premise. Learn more about the BCG matrix on Wikipedia.

import pandas as pd
import numpy as np
from sklearn.ensemble import GradientBoostingRegressor
from anthropic import Anthropic
import json

class MenuEngineeringAnalyzer:
    """Classic menu engineering matrix + ML extensions"""

    def classify_menu_items(self, sales_data: pd.DataFrame) -> pd.DataFrame:
        """
        Boston Consulting Group matrix for menus:
        - Stars: high margin + high popularity → keep, promote
        - Puzzles: high margin + low popularity → rename/reposition
        - Plowhorses: low margin + high popularity → reduce cost
        - Dogs: low margin + low popularity → remove
        """
        df = sales_data.copy()

        # Normalized metrics
        median_popularity = df['orders_count'].median()
        median_margin = df['contribution_margin_pct'].median()

        df['high_popularity'] = df['orders_count'] > median_popularity
        df['high_margin'] = df['contribution_margin_pct'] > median_margin

        def classify(row):
            if row['high_popularity'] and row['high_margin']:
                return 'star'
            elif not row['high_popularity'] and row['high_margin']:
                return 'puzzle'
            elif row['high_popularity'] and not row['high_margin']:
                return 'plowhorse'
            else:
                return 'dog'

        df['category'] = df.apply(classify, axis=1)

        # Additional metrics
        df['revenue_share'] = df['total_revenue'] / df['total_revenue'].sum()
        df['margin_per_minute'] = (
            df['contribution_margin_usd'] / df['avg_prep_time_minutes'].clip(1)
        )

        return df.sort_values(['category', 'contribution_margin_usd'], ascending=[True, False])

    def compute_menu_mix_impact(self, items: pd.DataFrame) -> dict:
        """What happens to revenue if menu changes"""
        stars = items[items['category'] == 'star']
        dogs = items[items['category'] == 'dog']
        puzzles = items[items['category'] == 'puzzle']

        return {
            'stars_revenue_share': stars['revenue_share'].sum(),
            'dogs_revenue_share': dogs['revenue_share'].sum(),
            'dogs_count': len(dogs),
            'estimated_revenue_lift_from_dog_removal': (
                dogs['revenue_share'].sum() * 0.6  # 60% of orders shift to stars
            ),
            'puzzles_reposition_opportunity': len(puzzles)
        }


class DemandForecastForMenu:
    """Dish demand forecasting for purchasing"""

    def __init__(self):
        self.models = {}

    def train_item_model(self, item_id: str, sales_history: pd.DataFrame):
        """Forecast model for a specific dish"""
        if len(sales_history) < 60:
            return

        features = self._build_features(sales_history)
        y = sales_history['orders_count']

        self.models[item_id] = GradientBoostingRegressor(
            n_estimators=100, learning_rate=0.1, random_state=42
        )
        self.models[item_id].fit(features, y)

    def _build_features(self, df: pd.DataFrame) -> pd.DataFrame:
        return pd.DataFrame({
            'weekday': df['date'].dt.weekday,
            'month': df['date'].dt.month,
            'is_weekend': (df['date'].dt.weekday >= 5).astype(int),
            'is_holiday': df.get('is_holiday', 0),
            'temperature': df.get('temperature_c', 15),
            'is_raining': df.get('is_raining', 0),
            'lag_7d': df['orders_count'].shift(7).fillna(0),
            'lag_14d': df['orders_count'].shift(14).fillna(0),
            'rolling_mean_7d': df['orders_count'].rolling(7).mean().fillna(0),
            'special_event': df.get('special_event', 0),
        }).fillna(0)

    def forecast_week(self, item_id: str,
                       next_7_days: pd.DataFrame) -> dict:
        """Weekly order forecast for inventory management"""
        if item_id not in self.models:
            return {'error': 'No model trained'}

        features = self._build_features(next_7_days)
        daily_forecast = self.models[item_id].predict(features).clip(0)

        return {
            'item_id': item_id,
            'daily_forecast': daily_forecast.round().astype(int).tolist(),
            'total_week': int(daily_forecast.sum()),
            'peak_day': next_7_days['date'].iloc[daily_forecast.argmax()].strftime('%A'),
            'confidence': 'high' if item_id in self.models else 'low'
        }


class MenuAIAdvisor:
    """LLM consultant for menu optimization"""

    def __init__(self):
        self.llm = Anthropic()

    def generate_optimization_report(self, menu_analysis: pd.DataFrame,
                                      restaurant_concept: str,
                                      season: str) -> str:
        """Report with menu recommendations"""
        stars = menu_analysis[menu_analysis['category'] == 'star'][['item_name', 'revenue_share']].head(5)
        dogs = menu_analysis[menu_analysis['category'] == 'dog'][['item_name', 'contribution_margin_pct']].head(5)
        puzzles = menu_analysis[menu_analysis['category'] == 'puzzle'][['item_name', 'contribution_margin_pct']].head(3)

        response = self.llm.messages.create(
            model="claude-3-5-sonnet-20241022",
            max_tokens=500,
            messages=[{
                "role": "user",
                "content": f"""You're a restaurant consultant. Provide menu optimization recommendations.

Restaurant concept: {restaurant_concept}
Season: {season}

Stars (keep & promote): {stars.to_dict('records')}
Dogs (consider removing): {dogs.to_dict('records')}
Puzzles (reposition/rename): {puzzles.to_dict('records')}

Provide specific recommendations in Russian:
1. Which dogs to remove and why
2. How to reposition puzzle items (name changes, placement, description)
3. How to leverage stars better
4. 2-3 seasonal items to consider adding
5. Pricing adjustments for plowhorses

Be specific. 3-4 paragraphs."""
            }]
        )
        return response.content[0].text

    def suggest_new_items(self, current_menu: list[str],
                           trending_ingredients: list[str],
                           cuisine_type: str) -> list[dict]:
        """Suggest new dishes based on trends"""
        response = self.llm.messages.create(
            model="claude-3-5-sonnet-20241022",
            max_tokens=400,
            messages=[{
                "role": "user",
                "content": f"""Suggest 3 new menu items for this restaurant.

Cuisine: {cuisine_type}
Current menu (sample): {current_menu[:10]}
Trending ingredients: {trending_ingredients[:8]}

For each item return JSON:
{{"name": "...", "description": "...", "main_ingredients": [...], "estimated_food_cost_pct": 25-35, "positioning": "starter|main|dessert"}}

Return JSON array. Suggest items that complement the current menu."""
            }]
        )
        try:
            return json.loads(response.content[0].text)
        except Exception:
            return []

What's Included in the Work

Module Result
Current menu analysis Stars/Puzzles/Plowhorses/Dogs matrix, recommendation report
Demand forecast Weekly forecast for each dish, ERP integration
LLM report Text document with recommendations in Russian, ready for printing
Dashboard Web interface (Streamlit/Tableau) with date and category filters
Staff training 2-hour session for managers, data update instructions
Warranty 3 months of post-deployment support, bug fixes

Results and Metrics

Metric Before Implementation After Implementation
Contribution margin Baseline +3-6 p.p.
Food waste 8-12% of purchases 15-25% reduction
Menu analysis time 3-5 days 2 hours
Demand forecast accuracy 60-70% 85-90%

Timeline and Cost

The system is developed turnkey in 2-4 weeks depending on the number of locations and data availability. Cost is calculated individually after an audit. We guarantee achieving the stated metrics (margin increase, waste reduction) within 3 months of launch.

We have over 7 years of experience in ML solutions for HoReCa and 30+ successful projects. We use an open-source stack (Python, Scikit-learn, Anthropic), eliminating vendor lock-in.

Contact us for a free demo analysis of your menu. Order a pilot project to discuss implementation.