Skip to content

pineapple-bois/Michelin_App_Development

Repository files navigation

Michelin Guide to France

An interactive Dash application for exploring Michelin-rated restaurants, French socioeconomic data, and wine appellations across France.

Links and recognition

Application pages

  • Guide: Search French locations, filter restaurants by geography and Michelin rating, and select map markers for restaurant details.
  • Analysis: Compare restaurant distributions and rankings across regions, departments, and arrondissements.
  • Economics: Explore socioeconomic indicators alongside Michelin restaurant distributions and optional starred-restaurant overlays.
  • Wine: Browse French AOCs by region or appellation, show regional outlines and starred restaurants, and select an appellation for generated information.

Technology

Built with Python 3.12, Dash, Flask, Plotly, pandas, GeoPandas, Flask-Caching, and the OpenAI API.

Local setup

git clone https://github.com/pineapple-bois/Michelin_App_Development.git
cd Michelin_App_Development

python3.12 -m venv .venv
source .venv/bin/activate

pip install -r requirements.txt
pip install -r requirements_dev.txt

On Windows, activate the environment with .venv\Scripts\activate.

Environment variables

Create a .env file in the repository root:

APP_ENV=development
OPENAI_API_KEY=<your-openai-api-key>
FLASK_SECRET_KEY=<local-development-secret>
  • OPENAI_API_KEY is required by the current import-time OpenAI client and powers Wine appellation information.
  • FLASK_SECRET_KEY is required in production. It is optional locally, where an omitted value produces a temporary key and sessions reset after restart.
  • OPENAI_REQUEST_LIMIT optionally sets the generated-information limit per session; the default is 10.
  • CACHE_TYPE and CACHE_DEFAULT_TIMEOUT optionally configure Flask-Caching; the defaults are process-local SimpleCache and 3600 seconds.
  • FORCE_HTTPS optionally overrides automatic production HTTPS handling.
  • DASH_DEBUG optionally enables Dash debug mode; the default is false.
  • APP_ENV, FLASK_ENV, or DASH_ENV set to production, or the presence of Heroku's DYNO, enables production defaults.

Running and testing

Start the application:

python michelin_app.py

Then open http://127.0.0.1:8050.

Run the test suite from the repository root:

python -m pytest

The tests do not send OpenAI requests, but application import still requires OPENAI_API_KEY to be configured.

Deployment

The production process declared in Procfile is:

web: gunicorn michelin_app:server

The deployment uses Python 3.12 and installs the GIS system packages declared in Aptfile. Production requires stable FLASK_SECRET_KEY and OPENAI_API_KEY values. HTTPS defaults to enabled when the environment is detected as production.

Project documentation

See AGENTS.md for the current architecture, module ownership, operating conventions, and validation guidance.

Licence and attribution

This project is released under the MIT Licence.

The Michelin Star logo is by Nikolaos Dimos and is used under CC BY-SA 3.0 via Wikimedia Commons.

About

Dash App - A Michelin Guide to France

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages