♻️ WasteWise
AI-Powered Waste Sorting
Inspiration
It started with a personal frustration. After learning about the scale of plastic pollution and the real environmental damage it causes, I genuinely wanted to change my habits and start recycling properly. But the moment I stood in front of a bin holding a piece of trash, I froze — does this go in recycling? Is it the right type of plastic? Does it need to be rinsed first? Every time, I had to pull out my phone, open a browser, and search for the answer. It was slow, inconsistent, and honestly discouraging.
That friction is exactly what kills good intentions. If doing the right thing is inconvenient, most people give up, not because they don't care, but because the information barrier is too high. I built WasteWise to remove that barrier entirely: snap a photo, get an instant answer, no searching required.
But beyond personal convenience, I saw a bigger opportunity. Every classification made through the app is a data point — what items are people sorting, in which cities, with what accuracy? That data has real value: it can be used to improve the AI model over time, and to study community recycling behaviours at a scale that's never been possible before. WasteWise isn't just a sorting tool — it's a way to learn how communities actually interact with waste.
What I Learned
- The data is as valuable as the app itself. Real user submissions create a ground-truth dataset of waste items by location — something that doesn't really exist at scale today. That data loop is where the long-term value of WasteWise lives.
- Multimodal AI is genuinely fast to integrate. Getting Claude Sonnet to classify waste images took less than an hour, the hard part was designing the prompt, not wiring the API.
- FiftyOne makes data pipelines invisible. It gave us structured analytics from day one, so we could focus on the product instead of building logging and visualization from scratch.
- Habit loops need rewards. A classifier alone wouldn't change behaviour. Points, badges, and streaks turn a one-time lookup into a daily habit — which is ultimately what drives both environmental impact and more training data.
How I Built It
Stack
| Layer | Tool |
|---|---|
| Frontend | Streamlit |
| AI Model | Claude Sonnet 4.6 |
| Analytics | FiftyOne |
| Storage | JSON + FiftyOne dataset |
Workflow
- User uploads or snaps a photo of their waste item
- Image is base64-encoded and sent to the Claude API with a structured prompt
- Claude returns item name, bin type (recycling / special / landfill ), and a confidence score (c) in [0, 1]
- Points are calculated and the result is saved to the FiftyOne dataset
- Leaderboard, badges, and impact stats update in real time
Points Formula
Each classification earns points based on bin difficulty and AI confidence:
P = B(bin) × confidence
Where B(bin) is the base point value per bin type:
| Bin | Base Points |
|---|---|
| Recycling | 100 pts |
| Special | 120 pts |
| Landfill | 25 pts |
Cost at Scale
For n images per user per month at $0.003 per image:
Monthly cost = n × $0.003
For a typical user sorting 20 items/month: 20 × $0.003 = $0.06/month.
Scaling to 10,000 monthly active users: just $600/month in AI inference costs.
Challenges
Prompt engineering for structured output Getting Claude to consistently return a parseable JSON object with item name, bin type, and confidence required several iterations. Edge cases like blurry images, multiple items in frame, or unusual angles initially produced inconsistent formats.
Session state in Streamlit
Streamlit reruns the entire script on every interaction. Managing user session state — keeping leaderboard data, badge progress, and streak counters consistent across reruns — required careful use of st.session_state and persistent JSON storage.
Mobile image upload UX Streamlit's default file uploader doesn't directly trigger the camera on mobile. We had to test multiple approaches to get a smooth "tap to snap" experience on phones without requiring a native app.
FiftyOne on Streamlit Cloud FiftyOne's full app requires a local server, which doesn't translate directly to a cloud-deployed Streamlit environment. We had to adapt the integration to use FiftyOne as a data layer and analytics backend rather than launching its interactive UI directly.
Log in or sign up for Devpost to join the conversation.