WTF Did Chat Put in the Database?
· Christine Ali
Building Weather With Regerts for Home Assistant
Home automation has a recurring problem: it is remarkably easy to make your house smart, and surprisingly difficult to make your house not annoying. Those are different engineering requirements. I’ve used Home Assistant for years because I want my house to behave the way I decide it should behave. I don’t particularly want a collection of disconnected manufacturer apps, each convinced that its light bulb, thermostat, weather station, or air purifier is the center of my technological universe.

Home Assistant fixes a lot of that. But eventually I ran into another problem. Weather reports are boring. I already have perfectly good weather data. Home Assistant knows the temperature. It knows humidity. It knows the forecast. Depending on the entities you have available, it can know wind, precipitation, air quality, particulate matter and a frankly unnecessary amount of information about what the atmosphere is doing.
What I did not need was another device solemnly announcing: “Today’s high temperature will be 103 degrees.” I live in the desert. At 103 degrees I am already aware that outside has become hostile. I wanted the computer to have an opinion about it. Thus was born Weather With Regerts.
The useful part
Weather With Regerts is a custom Home Assistant integration. It doesn’t replace your weather provider and it doesn’t attempt to become one. You point it at the weather entity you already trust, optionally give it other sensor entities for things such as humidity, wind, precipitation or air quality, and it turns those boring measurements into commentary. The important architectural decision is that the jokes don’t determine the facts.
Home Assistant and the configured sensors determine the facts. Weather With Regerts classifies those facts and selects commentary appropriate to the conditions. That means the system can be ridiculous without being unreliable. There is a difference between: “The temperature is 106 degrees and the sun has chosen violence.” and: “The language model feels like it might be warm today.” One is useful information with an attitude problem.
The other is an AI hallucination wearing a meteorologist costume. I wanted the first one. The integration exposes its output as a normal Home Assistant sensor, so once it exists in HA I can use it anywhere else I would use an entity: dashboards, automations, notifications, text-to-speech, morning briefings, or whatever other questionable decision I make next. Then I made the mistake of asking ChatGPT to help populate the phrase database.
WTF did Chat put in the database? – The sun is made of prefabulated Amulite

I want to establish something before continuing. The software worked. This is important. The weather classification worked. The phrase-selection system worked. The database loaded. The sensor produced output. Then I started actually reading the content we had generated. There were reasonable entries. There were funny entries. And then there were sentences that caused me to stare at the screen and wonder exactly what sequence of decisions had brought us here.
For heat, Chat gave me: “The sun has chosen violence.” Fair. For humidity: “The atmosphere has become soup.” Also fair. For rain: “It’s raining cats and dogs. Please check the yard for Labradors.” That one survived. Wind eventually produced: “It’s windier than a Taco Bell during a chalupa sale.” I have questions about the fluid dynamics involved, but I’m willing to accept the premise. Then we started adding reference packs.
Star Wars could produce: “Tatooine is cooler right now.” Dungeons & Dragons contributed: “The wind rolled a natural 20 against your patio furniture.” Star Trek gave us: “The warp core is cooler than the sidewalk.” And somewhere in the phrase corpus there is: “The weather API is returning sarcasm instead of data.” At this point the software had developed a personality. Then I inspected some of the unfiltered phrase generation.
That was when things became art. At 112°F and above, one generated entry reads: “No Regerts has become Yes, Fucking Regerts under this surface-of-hell hot.” Another: “Gondor has become a fucking argument against going outside.” And one particularly exhausted ranger apparently opened: “a formal ticket titled ‘what the fuck.’” I was supposed to clean this up. Instead, I kept the files. Because obviously I did.
It got an architecture
Once I realized this was becoming an actual project rather than one stupid automation that made me laugh, I separated the phrase system into packs. There is a base phrase collection, and then optional reference packs can extend it. Geek references can be enabled independently from Star Trek. D&D doesn’t require Star Trek. Star Wars, Dune, Lord of the Rings, Terminator, California desert references, food jokes and other packs can be switched on or off independently.
The phrase engine doesn’t need to care where a sentence came from. Once selected packs are loaded, they become one normalized active phrase database. The implementation tracks phrase origin for debugging, because apparently I have reached the point in my career where I need observability to determine which fandom made my weather station swear at me. The system is also deterministic within its rotation window. Restarting Home Assistant shouldn’t cause the weather personality to develop sudden amnesia and immediately choose a different sentence for exactly the same conditions. Changing the enabled packs does intentionally change the selection.
There is even a runtime reload action, weather_with_regerts.reload_phrases, because restarting an entire home-automation server just to make the weather station learn a new Lord of the Rings joke would be ridiculous. There are standards. The integration keeps the base phrases, enabled packs, and an optional user overlay separate. My own local additions can live in /config/weather_with_regerts/phrases.yaml, which loads last and extends the built-in database. The active phrase database is cached rather than being rebuilt every time a weather entity twitches.
This is, somehow, now real software.
Installing Weather With Regerts
Weather With Regerts is designed as a Home Assistant custom integration and can be installed through HACS. If you already have HACS, add the Weather With Regerts GitHub repository as a custom repository in HACS and select Integration as the repository type. HACS’s current custom-repository flow is the three-dot menu → Custom repositories → enter the repository URL → select the appropriate type → Add. After installing the integration, restart Home Assistant, then go to Settings → Devices & Services → Add Integration and search for Weather With Regerts.

From there, select the weather.* entity you want it to use as its primary source. Optional sensor overrides can provide other measurements when you have better local sources available. On my system that matters because home automation is considerably more interesting when the house knows what is happening at the house, rather than at an airport twenty miles away. After setup, configuration lives in Settings → Devices & Services → Weather With Regerts → Configure. That’s also where reference packs can be selected. The integration supports independent packs such as Geek, Star Trek and D&D rather than forcing all of the references into one giant nerd soup.
If you don’t already have HACS, its official documentation covers installation. HACS is community software and its own documentation recommends backing up Home Assistant before installing community integrations. That is good advice. Your smart home should not become a very expensive collection of dumb light switches because you wanted the forecast to insult you.
The accidental engineering lesson
Weather With Regerts began as a joke, but I actually like the architecture that came out of it. The generative part of the project produced language. It did not receive authority over reality. Temperature is data. Humidity is data. Wind speed is data. The forecast is data. Whether 112 degrees should be described as “surface-of-hell hot” is presentation. Keeping those layers separate means I can let the presentation layer be creative, sarcastic and occasionally completely deranged without compromising the underlying information.
I think that’s a useful pattern for AI systems generally. AI doesn’t need to own the whole decision to be useful. In fact, frequently it shouldn’t. Give deterministic systems authority over things that need to be deterministic. Give generative systems the parts where variation, language and interpretation are useful. Define the boundary between them. Then test the hell out of the boundary. Weather With Regerts now has thousands of phrases across multiple reference packs, validation tooling, tone levels, deterministic selection, runtime reloads, source metadata and automated tests.
This is an objectively unreasonable amount of engineering for making the weather swear at me. I regret nothing. Or, more appropriately: I have regerts. Source and setup details: Weather With Regerts README and HACS custom repositories.
Discover more from Christine Alifrangis
Subscribe to get the latest posts sent to your email.
Leave a Reply