DEV Community

Cover image for Mauka: when is it actually okay to go outside? (TabPFN + Gemma, running on my laptop)
Prashi Jain
Prashi Jain

Posted on

Mauka: when is it actually okay to go outside? (TabPFN + Gemma, running on my laptop)

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

If you live in a hot, smoggy Indian city, "just go outside for a bit" is not simple advice. By afternoon it is too hot. In winter the air is bad all day. In the monsoon it rains. The good hours exist, but they are short, and they move around from day to day.

So I built Mauka (मौका, Hindi for "chance" or "moment"): a small app that tells you which hours of tomorrow are most likely to be good for being outside.

In short

  • It predicts, for every hour from 05:00 to 21:00, the chance that it will be a good hour tomorrow.
  • It uses TabPFN on open weather and air-quality data, and a small Gemma model that runs on my own laptop writes the nudge in English, Hinglish or Hindi.
  • Nothing personal leaves my machine, and there is no API key and no bill.
  • I tested it in four cities. The learned models clearly beat simple baselines, and TabPFN was best, but only slightly.

What I Built

Mauka shows tomorrow as a strip of hours. Taller, bluer bars mean a better chance. Under the strip it lists the best windows, and below that is a short nudge, for example "Your best window tomorrow is 05:00 to 09:00."

A "good hour" means all three of these are true: US AQI of 100 or less, a "feels like" temperature between 8 and 35 °C, and no real rain. That is my own simple definition, not medical advice, and it is one line to change in the config file.

The screen is the shortest part of the experience on purpose. You open it, read one line, and go.

Demo

Demo video: uploading now, and this link will be updated shortly. Screenshots of the app running are above.

Code

GitHub logo prashijain-ai / mauka-outdoor-windows

Find your moment outside: a local-first AI guide to the clean-air hours of a hot, hazy city (TabPFN + Gemma)

Mauka (मौका) 🍃

Find your moment outside. A local-first AI guide to the clean-air hours of a hot, hazy city, built on open data and open models that run on your own laptop.

Mauka screenshot

Started: October 10, 2026, for the Hacktoberfest 2026 DEV Challenge (Week 1: Touch Grass).

What it does

In many Indian cities, the good hours for being outside are short and change every day. Mauka predicts, for each waking hour of tomorrow (05:00 to 21:00), the chance that it will be a good hour, then shows the best windows and a short nudge.

A "good hour" means all of these are true:

  • US AQI of 100 or less
  • "Feels like" temperature between 8 and 35 °C
  • No real rain (0.5 mm or less)

These limits are my own simple definition, not medical advice. You can change them in mauka/config.py.

How it works

  1. Data: hourly weather (ERA5) and…

How I Built It

The data. Hourly weather (ERA5) and air quality (Copernicus CAMS) history from the free Open-Meteo API, saved locally as CSV.

The task. Each row is one hour of one day. From the conditions at that hour plus recent history (yesterday's and 3-day average air quality, the day's peak temperature), the model predicts whether the same hour tomorrow will be good.

The models. TabPFN is the main model. It is a pretrained model for tabular data, which suits this problem because the dataset is small enough for it. To check whether it actually helps, I compared it with four simple baselines: persistence ("tomorrow equals today"), climatology (the historical rate for that month and hour), logistic regression and gradient-boosted trees.

The test. I split by time, not at random: the last 25% of days (2025-09-18 to 2026-10-02) are the test set, with a one-day gap so no training answer overlaps a test input. I ran four cities. Each cell is AUC / Brier score (higher AUC is better, lower Brier is better):

City Good hours Persistence Gradient boosting TabPFN
Bengaluru 69% 0.749 / 0.208 0.870 / 0.130 0.894 / 0.115
Chennai 40% 0.776 / 0.207 0.896 / 0.129 0.908 / 0.122
Mumbai 34% 0.792 / 0.181 0.901 / 0.122 0.914 / 0.111
Udaipur 71% 0.800 / 0.160 0.902 / 0.106 0.915 / 0.102

The full table (accuracy, F1 and all five models) is in results/summary.md in the repo.

What I take from it. TabPFN had the best Brier score and AUC in all four cities, and every learned model clearly beat persistence and climatology. But TabPFN's lead over gradient boosting is small: Brier lower by 0.004 to 0.015, AUC higher by 0.012 to 0.024. This is one split and one run per city, with no confidence intervals, so I treat the gaps as suggestive, not proven. A few details so the comparison is fair:

  • TabPFN trained on a random 4,000-row sample, while the baselines used all training rows (for example 19,346 in Bengaluru).
  • The test set is a 3,000-row sample from the last quarter of the data.
  • TabPFN took about 45 seconds per run, against under a second for gradient boosting.
  • Accuracy and F1 are less useful than Brier and AUC here, because the share of good hours changes so much between cities. In Udaipur, repeating today's answer already scores 0.834 accuracy.

The nudge, and what went wrong first. A small Gemma (gemma3:1b) running locally through Ollama writes the message. My first version let it see weather numbers, and it started making things up: "the sun is shining", "boost your mood", and it said "today" about tomorrow's forecast. None of that was in my data.

The fix had two parts. I gave the model only the window times and the chance, and I added a check: the text must contain the exact best-window times and avoid a list of invented claims. If it fails, the app retries once and then falls back to a plain template. The app always shows which one wrote the text. Hindi from a 1B model is readable but generic.

Limits. The data is gridded (ERA5 and CAMS), not street-level sensors. Predictions use archived "today" values, while live use mixes observations and forecasts for the rest of today. The thresholds are a simple idea of "good", and results will differ by city and season. I built Mauka with the help of an AI assistant (Claude), then ran, tested and reviewed it myself, and the repo has 9 tests.

Why Does Open Innovation Matter?

  • Privacy by default. The models run on my laptop. The only network calls are public weather and air-quality requests. A tool like this could one day use personal habits or health information, and that should not have to go to a server I don't control.
  • No key and no bill. After the one-time download, TabPFN and Gemma run on a normal laptop with no API key and no per-call cost.
  • Inspectable. The data, the thresholds and the evaluation are all visible, so anyone can check the claims or change what "good" means for their own needs, such as a stricter air-quality limit for someone with asthma.
  • Swappable. Changing the Gemma model is one setting, and adding a city is one line.

It was not all better than a closed model. A 1B-parameter model writes plain text and needed guardrails, and my first version invented facts. TabPFN's weights are open but come with Prior Labs' license terms, which I accepted, so check them before any commercial use. Fetching fresh weather still needs the internet, even though the models run on-device.

What I Learned

  1. Strong baselines matter. Persistence alone gets surprisingly far, so a model has to beat it clearly to be worth using.
  2. Small models need guardrails. Checking the output against the data was more useful than a cleverer prompt.
  3. An honest small win is fine. TabPFN was best everywhere I tested, and I would rather report a small, consistent edge than oversell it.

Next: more cities, user-set thresholds, and a version that learns from your own outdoor log.

Prize Categories

  • Best Use of TabPFN: TabPFN forecasts, from historical weather and air-quality data, which hours of tomorrow will be good.
  • Best Use of Gemma: Gemma runs locally and writes the nudges in English, Hinglish and Hindi.

Top comments (1)

Collapse
 
suppdevbot profile image
Info Comment hidden by post author - thread only accessible via permalink
DEV SUPPORTS •
You need to verify your account.
Enter fullscreen mode Exit fullscreen mode

tr.ee/dev-to

Some comments have been hidden by the post's author - find out more