cd /news/artificial-intelligence/build-ecoroute-a-smart-city-waste-an… · home topics artificial-intelligence article
[ARTICLE · art-110118] src=dev.to ↗ pub= topic=artificial-intelligence verified=true sentiment=↑ positive

Build EcoRoute: A smart City Waste and Circular Economy Engine.

A team of developers built EcoRoute, an end-to-end platform for smart city waste management and circular economy, during a hackathon. The platform combines real-time waste monitoring, AI fill prediction, Go-powered route optimization, citizen reporting, and a marketplace that traces recycled materials to products. The system uses a Go backend with PostgreSQL and a React frontend with Leaflet, and includes features like nearest-neighbor route optimization and a provenance ledger.

read3 min views2 publishedAug 25, 2026

Build a full-stack, production-grade project during a hackathon

When our team set out to compete in the Smart Cities and Route Optimization track, we didn't want to build just another static mapping app that plots static points. Municipal waste managment in fast-growing urban centers faces major operational challenges:

  • Inefficient truck that burn unnecessary fuel
  • Zero real-time visibility into bin fill levels
  • Poor integration with post-collection recycling economies.

we decided to build EcoRoute an end-to-end platform that:

  • Combines real-time waste monitoring
  • AI fill prediction
- Go-powered route optimization
- Crowd-sourced citizen reporting
  • A circular marketplace that traces recycled waste directly to retail products. The Problem Urban waste collection in many developing cities suffers from three core issues:

Static, Inefficient Routes: Refuse trucks follow rigid, predetermined routes regardless of whether bins are empty or overflowing. This waste driver time , spikes municipal fuel expenses and increases carbon emissions. 2.Reactive Collection and Poor Citizen Feedback: Bins overflow before cities notice. Citizens have no direct channel to report illegal dumping or missed pickups, leading to dalayed escalations. 3.Disconnected Recycled Lifecycles: Waste collection is treated as an endpoint rather than the start of a supply chain. Recyclers and consumers lack transparency regarding where recycled raw materials come from. The solution #

Waste monitoring and AI predictions Live Interactive Map: Color-coded status markers show full bin locations in real-time. AI Fill Forecasting: A lightweight microservice predicts tomorrows fill level per point so logistics teams can plan ahead proactively. EcoMarket Circular Economy:* A closed-loop marketplace where products made from recovered waste are traced back to the specific waste collection batch they originated from.

Key Features

Waste Monitoring & AI Predictions

Live Interactive Map: Color-coded status markers show full bin locations in real time.

AI Fill Forecasting: A lightweight microservice predicts tomorrow's fill level per point so logistics teams can plan ahead proactively. #

Resilient Architecture: If the AI service drops, the backend gracefully degrades to historical baselines to prevent dashboard crashes (500

errors).

Route Optimization & Driver Workflows

Nearest-Neighbor + 2-Opt Reordering: Instantly re-sequences stops to cut total transit distance. #

Savings Delta: Computes and saves before/after comparative metrics for distance (km), fuel (L), and time saved per collection run. #

Driver Execution UI: Step-by-step mobile driver interface to log collections, mark completion, or flag failed pickups.

*Community Reporting **

  • Citizens upload geotagged photos of illegal dumping or overflowing bins.
  • Submitting a report automatically escalates the linked waste point to critical

status, forcing immediate route re-calculation.

EcoMarket & Provenance Ledger

  • Waste collected is weighed (kg) and broken down by category (PET plastics, metals, paper).
  • Manufacturers convert these Recycling Material Batches into commercial products sold on EcoMarket.
  • Buyers click Trace Material Origin to view the full lineage: Waste Point

Collection Run

Recycling Batch

Finished Product

, with simulated M-Pesa automated seller payouts.

How It Was Built & Tech Stack

We organized the project into a clean monorepo structure to accelerate parallel development:

The Backend (Go 1.26 + PostgreSQL 16)

The API core was built in** Go 1.26** using standard library routing (net/http) and pgx/v5 for PostgreSQL connectivity.

** Algorithms**: We implemented a local Nearest-Neighbor heuristic combined with 2-Opt edge swapping directly in Go to reorder stop arrays deterministically.

The Frontend (React 19 + Leaflet) Built using React 19, Vite, react-router 7, and Leaflet / react-leaflet.

  • Dynamic map layer rendering color-coded pins based on real-time fill percentages.
  • Separate, role-tailored interface views for Admins, Drivers, Community Members, and Marketplace Seller s.

The AI Prediction Service (Python) A lightweight Python service exposing a simple HTTP contract (POST /predict) that calculates expected fill trajectories based on recent historical fill velocity.

Building a full-stack monorepo with AI prediction, real-time map rendering, custom algorithms, and circular economic ledgers in 72 hours required deep trust and domain ownership:

Any comment and suggestion on the platform

── more in #artificial-intelligence 4 stories · sorted by recency
── more on @ecoroute 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/build-ecoroute-a-sma…] indexed:0 read:3min 2026-08-25 ·