Local Flavor Bot is a recipe recommendation chatbot that suggests recipes based on ingredients or dish preferences. The bot uses the Spoonacular API for recipe data and implements semantic search for better results.
You can try out the live version of the Local Flavor Bot here: https://flavorbot.akgns.com/
- Web UI for easy search
- Semantic search by using transformer models
- Rate limiting to prevent API abuse
- Detailed recipe information including:
- Time
- Servings
- Ingredients list
- Instructions
- Source URL
- Clone the repository:
git clone [repository-url]
cd flavor-bot
- Create a virtual env and activate it:
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
- Install required packages:
pip install -r requirements.txt
- Create a
.env
file in the project root and add your Spoonacular API key:
API_KEY=your_spoonacular_api_key_here
Run the application:
python recipe_finder.py
Then open your browser to navigate to the web interface.
-
Clone the repository:
git clone https://github.com/ckakgun/flavor-bot.git
cd flavor-bot
-
Create and activate a virtual environment:
python -m venv
venv source venv/bin/activate
On Windows, use
venv\Scripts\activate
-
Install the required packages:
pip install -r requirements.txt
-
Run the application:
python recipe_finder.py
-
The application should now be running on
http://localhost:5001
.
- Build flavor-bot :
docker build -t flavor-bot:latest -f docker/Dockerfile .
- Run image :
docker run -p 5000:5001 -e API_KEY=your_spoonacular_api_key_here -it flavor-bot
- The application can be accessed on
http://localhost:5000
while docker container(flavor-bot) is running on 5001th port.
- "Show me some pasta recipes"
- "Vegetarian dinner ideas"
- "What can I cook with potatoes and cheese?"
- "Quick dinner recipes under 30 minutes"
- "Italian pasta dishes"
The application includes rate limiting to prevent excessive API usage:
- Maximum 5 requests per 5 seconds per IP address (Local rate limiting)
- Maximum 150 requests per day (Spoonacular API limit)
- When the daily API limit is reached, users will be notified
- Applies to both web and CLI interfaces
Note: The Spoonacular API has a daily limit of 150 requests with the free tier. Once this limit is reached, the application will notify users to try again the next day.
- Flask for web interface
- Sentence Transformers for semantic search
- Requests for API calls
- Python-dotenv for environment variables
- PyTorch for tensor operations
MIT License