FoodPrint – Preserving African Indigenous Food Knowledge
# FoodPrint – Preserving African Indigenous Food Knowledge
FoodPrint is an AI-powered web application that identifies African plants, fruits, berries, roots, and leaves from photos using OpenAI's GPT-4o vision model.
## How Codex Was Used
I used **Codex** (OpenAI's agentic coding tool) to generate the entire application:
- Full Flask backend (`app.py`) with image preprocessing and API integration
- Mobile-first frontend (`static/index.html`) with drag-and-drop upload
- Deployment configuration (`Procfile`, `requirements.txt`, `runtime.txt`)
- The complete project structure and all core functionality
Codex accelerated development by generating production-ready code from natural language prompts, allowing me to build a full-stack AI app in hours rather than days.
## How GPT-4o Was Used
I used **GPT-4o** (OpenAI's vision model) for:
- Plant identification from user-uploaded photos
- Generating structured JSON output with:
- Common name, local names (Yoruba, Igbo, Swahili, Hausa)
- Nutritional profile (vitamins, minerals, sugar, starch, protein, fiber)
- Eco-Score (carbon footprint, water usage, sustainability tips)
- Health goal insights, traditional uses, and cultural significance
I engineered a custom system prompt that positions GPT-4o as an expert African Ethnobotanist, ensuring accurate, culturally-aware identifications.
## Tech Stack
- **Backend:** Flask (Python)
- **AI Model:** OpenAI GPT-4o (vision)
- **AI Agent:** Codex
- **Image Processing:** Pillow (PIL)
- **Frontend:** HTML, CSS, JavaScript (mobile-first)
- **Deployment:** Render + Gunicorn
## Live Demo
foodprint-pl9c.onrender.com
## Setup Instructions
1. Clone the repository
2. Create a `.env` file with your `OPENAI_API_KEY`
3. Run `pip install -r requirements.txt`
4. Run `python app.py`
5. Open `
localhost`