DEV Community

Aditya
Aditya

Posted on

FoliageRun — Autonomous Autumn Canopy Route Synthesizer for Bhubaneswar published: true

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 1: Touch Grass

What I Built

FoliageRun is an autonomous running route synthesizer created to help developers and runners disconnect from screens and explore the outdoor canopy of Bhubaneswar, Odisha.

Urban runners frequently end up on high-traffic, polluted roads simply because standard GPS navigation prioritizes vehicular speed over greenery. FoliageRun solves this by orchestrating an open-source AI agent workflow that:

  • Ingests a runner's custom starting point, ending point, or distance target.
  • Maximizes tree-canopy coverage across major green corridors (such as Ekamra Kanan, Jayadev Vatika, and Chandaka trails).
  • Synthesizes realistic running loops and generates turnkey GPX 1.1 exports compatible with Garmin, Strava, and Apple Watch.
  • Provides a tranquil, distraction-free "Lock Screen" dispatch mode that encourages users to pocket their devices and touch grass.

Demo

Code

GitHub logo AdityaNarayanPadhi / FoliageRun

An open-source autumn running route generator for Bhubaneswar, Odisha. Built for the Hacktoberfest 2026 Touch Grass challenge.

🍂 FoliageRun Backend Service

Hacktoberfest 2026 "Touch Grass" Challenge Entry
An autonomous outdoor autumn running route generator powered by the Mastra framework, open-weight LLMs via Groq / Hugging Face Inference API, OpenStreetMap Overpass API, SerpApi, and telemetry tracked by Sentry AI Agent Monitoring.


🧭 Overview

FoliageRun encourages runners and outdoor enthusiasts to get outside and "touch grass" during peak autumn foliage. Given a starting point and desired distance (e.g., 5km, 10km), the backend orchestrates specialized agents and tools to synthesize a closed-loop running route that maximizes tree canopy coverage, routes through local parks, and includes live foliage condition reports and turnkey GPX export for Garmin, Strava, and Apple Watch.


🛠 Architectural Stack

  • Runtime & Language: Node.js (v20+ / v22+), TypeScript, Express
  • Agent Orchestration: Mastra Framework (@mastra/core)
  • Open-Weight LLMs: google/gemma-2-9b-it or meta-llama/llama-3.1-8b-instant via Groq API or Hugging Face Inference API using…

The repository is fully open-source under the MIT License and includes:

  • Express + TypeScript backend orchestrator with Mastra Agent tooling.
  • Dynamic OSM Overpass query integration for parsing parks and green paths.
  • SerpApi tool integration for live foliage reports.
  • Sentry OpenTelemetry instrumentation for AI agent monitoring.

How I Built It

FoliageRun combines modern open-weight AI inference with real-time geospatial extraction:

  1. Agent Orchestration (Mastra): Built with @mastra/core to coordinate external tools, handle context windows, and manage tool-calling lifecycles.
  2. Open-Weight Inference (Gemma 2 9B): Powered by google/gemma-2-9b-it via Groq's high-speed endpoint. Gemma synthesizes optimal running waypoints, elevation estimates, and natural turn-by-turn briefings without proprietary closed-model lock-in.
  3. Geospatial & Foliage Tools:
    • OpenStreetMap Overpass API: Live queries identify paths, parks (leisure=park), and nature reserves (landuse=forest) around Bhubaneswar.
    • SerpApi: Retrieves live seasonal canopy status, weather advisories, and park trail conditions.
  4. Telemetry & Tracing (Sentry AI Monitoring):
    • End-to-end tracing across ai.agent, ai.tool, and ai.chat_completions.create spans.
    • Monitored latency, error rates, and prompt/completion token consumption directly within the Sentry dashboard.

Why Does Open Innovation Matter?

Outdoor well-being and navigation tools should not depend entirely on opaque, closed-source ecosystems.

Open innovation makes it possible to:

  • Pair community-maintained datasets like OpenStreetMap with open-weight models (gemma-2-9b-it), ensuring anyone can self-host and customize route synthesis for their own city without incurring per-query subscription fees.
  • Transparently inspect how route decisions are made, avoiding proprietary ad-driven route biases.
  • Give developers complete ownership over telemetry and data governance by pairing open-source toolkits with transparent observability platforms.

Prize Categories

  • Best Overall Touch Grass Project
  • Best Use of Mastra (Used @mastra/core for agent workflow execution and multi-tool orchestration)
  • Best Use of Sentry Agent Tracing (Integrated @sentry/node capturing automated spans for ai.agent, tool execution latency, and token consumption metrics)
  • Best Use of Gemma (Deployed gemma-2-9b-it for intelligent spatial waypoint reasoning and running briefing generation)

Top comments (0)