What Color Was The Sky

2 min read Original article ↗

Every sky on this page is reconstructed from real data. The words were written by a human. A few honest footnotes follow.

  • Atmospheric data · clouds, humidity, precipitation

    High, mid, and low cloud cover at the hour nearest sunset, plus relative humidity and precipitation. Free, CC-BY-4.0 licensed, no API key required.

  • Air quality · smoke, dust, pollution

    PM2.5, PM10, dust, and US AQI. Thresholds are ours; the ratio of PM2.5 to PM10 is used to distinguish combustion smoke from urban particulate. The thresholds are tuned for common cases and may misfire at the extremes.

  • Where the fires were

    Geographic and seasonal heuristic

    When smoke is detected, the prose names a likely source (Sonora, Quebec, the Amazon, and so on) based on latitude, longitude, and month. This is a guess. If the smoke you were breathing came from somewhere else, the sky was still doing what the prose says.

  • Sunset time and sun angle

    NOAA Solar Position formulas · public domain

    Computed in the browser. The angle used is the sun's altitude ten minutes before sunset, which is about when the color happens.

  • The physics of color

    Simplified Rayleigh + Mie scattering model

    This is not a photorealistic simulation. It is an interpretive model, closer to an impressionist painting than a spectrograph. Aerosols shift the horizon redder; shallow sun angles amplify the warming; humidity softens everything. If the real sky was more dramatic than ours, it usually was.

  • Geocoding · your city to coordinates

    We try the full input first. If that fails, we extract a qualifier (everything after a comma, or the last word) and use it to filter multiple results, so "Paris, Texas" and "Paris Texas" both correctly resolve to Paris, TX rather than Paris, France. The meta line always shows the matched city so you can confirm which one.

  • The prose

    Hand-written · Combinatorial, not generative

    Around a hundred sentences written by Matt, assembled by conditions. No LLM writes or rewrites anything at runtime. If a condition isn't covered, the prose stays quiet about it. We'd rather leave a line out than fake one.

  • A sister piece

    Since You Arrived asks a similar question about a different thing: what the world did while you were reading a tab. Vol. I of what is now, apparently, a series.