DEV Community

Ahan Ghosh
Ahan Ghosh

Posted on

TrailSense AI — Offline Nature Quest & Sensory Walk Companion Powered by Gemma 2

Hacktoberfest Open-Source AI Challenge Week 1: Touch Grass Submission 🌿

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

What I Built

I built TrailSense AI — an offline-first nature exploration companion designed to combat chronic screen fatigue among developers, students, and desk workers.

Instead of keeping people glued to a phone while outdoors, TrailSense AI is built around a single rule: make the screen the shortest part of the experience.

It takes just 30 seconds to choose your outdoor setting (Campus Quad, City Park, Forest Trail, or Neighborhood) and duration (15, 30, or 45 minutes). Local open-weight AI then synthesizes a personalized, tangible sensory micro-quest:

  • 🍂 Foliage Quests: Compare leaf margin serrations between oak and maple species.
  • 👂 Soundscape Quests: Filter out urban hum to isolate two distinct bird calls or wind rustles.
  • 🪵 Tactile Quests: Inspect trunk bark textures (smooth birch lenticels vs deep furrowed oak).

Once generated, you pocket your phone. Gentle, non-intrusive 528 Hz audio chimes announce walk milestones and cue a 2-minute stillness mindfulness pause under a tree canopy. A built-in botanical reference identifies species with zero cell signal, and when you return, you log your findings in an offline nature journal.

Demo

🔗 Live Website: https://trailsense-ai.vercel.app/

Try it out live — select an outdoor environment, pick your duration, and generate a sensory nature quest. Features you can test:

  • Offline Nature Quest Dispatcher: Generates non-digital observational challenges tailored to your location.
  • Pocket Mode Timer: Hands-free walk tracking with gentle Web Audio chimes so your phone stays in your pocket.
  • Offline Field Guide: Built-in tree and bird identification reference that works without internet.
  • Nature Journal & Streaks: Log field notes and track your "Days Touched Grass" streak.

Code

TrailSense AI 🌿🍂

Offline Nature Quest & Sensory Walk Companion
Built for Hacktoberfest 2026 Week 1: "Touch Grass" Challenge


🍃 Why TrailSense AI?

Modern developers and students spend 10+ hours a day staring at glowing screens. Even when we step outside, we often find ourselves mindlessly looking down at notifications, step counts, or social feeds.

TrailSense AI was built on a simple philosophy:

"Make your screen the shortest part of your day."

Spend 30 seconds on the screen to receive a sensory nature mission, pocket your phone, and let gentle audio chimes guide you through an immersive outdoor micro-quest.


✨ Features

  • 🧭 Context-Aware Nature Quest Dispatcher: Choose your environment (Campus Quad, Urban Park, Forest Trail, Neighborhood) and duration (15, 30, or 45 minutes).
  • 🧠 Powered by Google Gemma 2 (2B): Uses local open-weight model inference via Ollama to generate creative observational challenges (leaf identification, soundscape listening, bark texture inspection).
  • 📴…

🔗 GitHub Repository: https://github.com/ahanghosh77/trailsense-ai.git

Tech Stack: Semantic HTML5, Vanilla CSS3 (dark forest glassmorphism), Vanilla JavaScript, Web Audio API, and local Gemma 2 via Ollama with an offline heuristic botanical matrix.

How I Built It

  1. Google Gemma 2 (2B) Prompt Architecture:
    I structured strict JSON-schema system prompts for Google's lightweight open-weight gemma2:2b model running locally via Ollama. The model acts as a sensory naturalist, producing concrete, non-digital observational tasks that balance visual, acoustic, and tactile outdoor discovery.

  2. Zero-Signal Offline Trail Architecture:
    Because the best places to touch grass (deep woods, parks, trails) frequently lack cell signal, TrailSense combines local browser execution with local Ollama inference and a client-side botanical fallback matrix, ensuring 100% functionality without internet.

  3. Screen Minimization:
    Instead of prolonged screen interaction, all missions are concise and supported by gentle audio notifications.

Why Does Open Innovation Matter?

Open innovation is essential for what TrailSense AI does:

  1. Trailside Independence: Proprietary cloud APIs fail the moment you lose cellular connection on a hiking trail. Open-weight models like Google's Gemma 2 run directly on personal devices with zero internet access.
  2. Privacy: Location habits, daily walk routines, and personal nature reflections never leave your device.
  3. Zero Cost: Open-source AI eliminates monthly subscriptions and API paywalls for students, hikers, and outdoor communities.

My Agent Session

This project was architected and built pair-programming with Google Antigravity, designing the local Gemma 2 prompt structure, the offline client-side botanical engine, and the Web Audio API pocket timer.

Prize Categories

  • Best Use of Gemma — TrailSense AI is built around Google's Gemma 2 (2B) open-weight model via Ollama, generating offline sensory nature quests and outdoor mindfulness challenges that empower developers and students to disconnect from screens and touch grass with zero subscription costs.

Top comments (0)