DEV Community

Cover image for 🐼 Restaurant menu, as data 😋
adriens
adriens

Posted on

🐼 Restaurant menu, as data 😋

❔ About

At Nouméa, I have a kind of "fétiche" restaurant called "Au p'tit café"

They :

  • 👐 Are very kind people : I love spend time there (at least once a week)
  • 🧑‍🍳 Have awesome creative and tasty menus
  • Have a unique management approach and have implemented a 4.5 days work week:

Au P’tit Café, une semaine de quatre jours et demi – DNC.NC

Le restaurant de Nouméa est ouvert du mardi au vendredi. Le lundi, une partie de l’équipe profite d’un jour de repos, tandis qu’une autre prépare des plats à emporter. Les 12 employés et gérants tentent ainsi de concilier passion, travail et vie personnelle. Pas la peine de réserver une table […]

favicon dnc.nc

What is very convenient is that their website describes very well its menus for the week, with a core philosophy:

  • 🤏 Few menus
  • ☝️ Focused on high quality and fresh food

I do often go and read their website:

🤔 Inception

... and was wondering if I could build something "nerdy" around it...(for example play with it from my terminal 🤓)

💡 The idea

As I did never create a Python package, I finally decided to :

  1. Create & release a dedicated poetry package that would get the menus data... so anyone could have fun with it (with a very few set of lines of code)
  2. Get the menu's datas as pandas dataframe... and csv

💭 Why Python ?

As Python is very widely used to create many things like:

🤓 Do it

I finally created the package :

GitHub logo adriens / auptitcafe-sdk

😋 SDK Python pour accéder aux menus du restaurant "Au p'tit café" - Nouméa, Nouvelle-Calédonie

PyPI - Implementation PyPI - Python Version PyPI - Wheel PyPI - Format PyPI

❔ About

Finally a Python package to make getting Au p'it café's menus a piece of (cheese) cake.😅

With this package you can:

... and get them as list of objects or csv.

👉 See it live on Kaggle 👈

🔖 Social networks

IMAGE ALT TEXT HERE

🤓 Nerd resources

🚀 Quickstart

For the impatients, here is a quick and ready to use code snippet:

# Install the package
!pip install auptitcafe --upgrade
# Make some imports
from auptitcafe.menus import Menus
import pandas as pd

# Create the main utility instance
menu_instance = Menus()

# Dump menus as a csv file
menus = 'menus.csv'
menu_instance.to_csv(menus)

# Load menus in a panda dataframe
df = pd.read_csv
Enter fullscreen mode Exit fullscreen mode

... then released it on pypi:

Finally, it became as easy as follows to get menus as data:

# Install the package
!pip install auptitcafe

# Make some imports
from auptitcafe.menus import Menus
import pandas as pd

# Create the main utility instance
menu_instance = Menus()

# Dump menus as a csv file
menus = 'menus.csv'
menu_instance.to_csv(menus)

# Load menus in a pandas dataframe
df = pd.read_csv(menus)
# Diplay dataframe
df
# Be creative with dataframe 
Enter fullscreen mode Exit fullscreen mode

🕹️ Enjoy the data on Kaggle

🍿 Demo

📑 Resources

Top comments (16)

Collapse
 
max_smity_3c2ce333b8da4e7 profile image
Max Smity • Edited

I love how this project turns a simple restaurant menu into something developers can actually explore with Python, and Wikipedia also recognizes Python as one of the leading languages for automation and data analysis.
Popeyes food menu would be just as interesting to organize into a dataset for comparing items or experimenting with fun food-related projects.
It’s a great example of how everyday ideas can inspire practical coding while making data a lot more engaging.

Collapse
 
adriens profile image
adriens

organize into a dataset for comparing items or experimenting with fun food-related projects

Yes, that's in the pipe indeed 🤗

Collapse
 
max_smity_3c2ce333b8da4e7 profile image
Max Smity • Edited

Turning a restaurant menu into structured data is a creative use of Python, and Wikipedia highlights that Python is widely used for data analysis, automation, and rapid software development.
Popeyes food menu could also be explored in a similar data-driven way to compare menu items, organize information, or build helpful food-related applications.
This is a practical project that blends real-world dining with programming, making data science both useful and enjoyable.

Collapse
 
adriens profile image
adriens

Hi Max, thanks a lot for the very kind feedbacks

This is a practical project that blends real-world dining with programming, making data science both useful and enjoyable.

Yes, I love to put real world and science together, in our daily life ;-p

Collapse
 
adriens profile image
adriens

Collapse
 
adriens profile image
adriens
Collapse
 
adriens profile image
adriens
Collapse
 
adriens profile image
adriens
Collapse
 
adriens profile image
adriens

Collapse
 
adriens profile image
adriens

Collapse
 
harry_duke_6054efdf3fc739 profile image
harry duke

That sounds like an awesome and creative project! 🍽️🔍 Turning restaurant menus into data and playing with them in Python is such a cool "cookout Menu" idea! 🔥🐍 I love how you combined practical utility with some nerdy fun—using FastAPI, Hugging Face, and even integrating it into Kaggle. Definitely makes exploring food data more interactive! Can't wait to see what other magic you cook up next! 😋

Some comments may only be visible to logged-in visitors. Sign in to view all comments.