Skip to content

WhiiteRose/FoodSaver-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

27 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

FoodSaver AI ๐ŸŒฑ

Hack for Humanity 2026

Reduce household food waste by 40% with AI-powered tracking and smart recipe suggestions.

๐ŸŒ Live Demo

https://foodsaver-ai.vercel.app/

๐ŸŽฏ The Problem

Every year, households waste 40% of purchased food, contributing to 8-10% of global greenhouse gas emissions. If food waste were a country, it would be the third-largest emitter of greenhouse gases globally

๐Ÿ’ก Our Solution

FoodSaver AI helps households reduce food waste through three intelligent features:

  • ๐Ÿฅ— Smart Pantry Tracker: Track food items and receive alerts before they expire
  • ๐Ÿค– AI Recipe Generator: Get personalized recipes using ingredients about to spoil
  • ๐Ÿ“Š Impact Dashboard: Visualize your environmental impact with real-time metrics

๐Ÿ“ธ Screenshots

๐Ÿฅ— Smart Pantry Tracker

Smart Pantry Tracker

๐Ÿค– AI Recipe Generator

AI Recipe Generator

๐Ÿ“– Recipes

Recipes

๐Ÿ“Š Impact Dashboard

Impact Dashboard

๐Ÿš€ Getting Started

Prerequisites

  • Node.js (v14 or higher)
  • npm or yarn
  • OpenAI API key (for recipe generation)

Installation

# Clone the repository
git clone https://github.com/WhiiteRose/FoodSaver-AI.git
cd FoodSaver-AI

# Install dependencies
npm install

# Create .env file with your OpenAI API key
echo "VITE_OPENAI_API_KEY=your_api_key_here" > .env

# Start the development server
npm run dev

The app will open at http://localhost:5173

Docker (Production)

# Build and run
docker compose up --build -d

# Open the app
http://localhost:8080

# Stop containers
docker compose down

You can also run without Compose:

docker build -t foodsaver-ai .
docker run --rm -p 8080:80 foodsaver-ai

โš™๏ธ CI/CD (GitHub Actions)

This repository now includes:

  • CI: .github/workflows/ci.yml
    • Runs on push and pull_request
    • Installs dependencies and builds the app
  • CD Vercel: .github/workflows/deploy-vercel.yml
    • Preview deploys on Pull Requests
    • Production deploy on the default branch (main or master)

Vercel setup

Add these repository secrets in GitHub (Settings > Secrets and variables > Actions):

  • VERCEL_TOKEN
  • VERCEL_ORG_ID
  • VERCEL_PROJECT_ID

How to get IDs quickly:

npx vercel link
cat .vercel/project.json

Then push to trigger deployment.

๐Ÿ› ๏ธ Built With

  • React - Frontend framework
  • Vanilla CSS - Styling with modern animations
  • OpenAI API - AI-powered recipe generation
  • Chart.js - Data visualization
  • Local Storage - Client-side data persistence

๐ŸŒ Environmental Impact

If just 10,000 households reduce food waste by 30%, we could prevent:

  • 1,500 tons of annual food waste
  • Equivalent to removing 500 cars from the road for a year
  • Conservation of thousands of gallons of water

๐Ÿ“ Features

Smart Pantry Tracker

  • Add food items with expiration dates
  • Categorize items (produce, dairy, meat, etc.)
  • Get notifications for expiring items
  • Quick-add common foods

AI Recipe Generator

  • Generate recipes based on expiring ingredients
  • Dietary preference support
  • Save favorite recipes
  • Share recipes with friends

Impact Dashboard

  • Track food saved (pounds)
  • CO2 emissions prevented
  • Water conserved
  • Money saved
  • Achievement badges and milestones

๐ŸŽฎ Usage

  1. Add Food Items: Click "Add Item" and enter your food details
  2. Get Alerts: Receive notifications when items are about to expire
  3. Generate Recipes: Click "Get Recipe" to create meals from expiring ingredients
  4. Track Impact: View your environmental contribution in the dashboard

๐Ÿค Contributing

This is a hackathon project, but contributions are welcome!

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

๐Ÿ“„ License

This project is licensed under the MIT License.

๐Ÿ‘ฅ Team

Created for Hack for Humanity 2026 Hackathon

๐Ÿ™ Acknowledgments

  • Hack for Humanity organizers
  • OpenAI for their API
  • The open-source community

Together, let's make a difference one meal at a time! ๐ŸŒ๐Ÿ’š

About

๐ŸŒฑ AI-powered food waste reduction app โ€” Track your pantry, get smart recipe suggestions from expiring ingredients, and visualize your environmental impact. Built with React, OpenAI API & Chart.js for Hack for Humanity 2026.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages