Mazza Builds
← All projects

5 to 9 · Trading bot

Kalshi Weather Trader

A bot that bets on tomorrow's weather.

Kalshi Weather Trader screenshot

4forecast models it weighs before every trade

  1. What it does

    It reads four different weather forecasts, works out the odds of tomorrow's high temperature landing in each range, and compares them with what the market believes.

  2. Why it's cool

    When the forecasts and the market disagree, it places a trade. It rechecks every 30 minutes and sends each move to my phone with its reasoning.

  3. The impact

    It runs on its own and keeps score every day, so how much it bets depends on how right its forecasts have actually been.

Under the hood

Context

Short-dated temperature contracts get mispriced when forecast distributions disagree with market-implied probabilities. The hard part is the meteorology, not the execution.

Build

Pulls multi-source forecasts from NWS, HRRR, GFS, and ECMWF ensembles, calculates probability distributions across temperature buckets, and acts only when modelled edge clears a threshold. Claude-powered agents re-evaluate every 30 minutes with position recovery and risk management. APScheduler drives the engine, SQLAlchemy persists state, and a Flask dashboard surfaces live performance.

Result

Runs autonomously with daily outcome tracking that feeds back into agent decisions, closing the loop between forecast accuracy and position sizing.

Stack

Python, Claude API, MCP, Flask

Links

Source

Next projectShopAI