So at work we license MS Copilot and I use Gemini quite a bit. For grins I told copilot to read all of the hubitat developer docs. I also let it read a exported rule of mine. Now, it can create new rules from scratch and I just have to import them. I will let y'all know how that goes
I can literally just tell it "make me a rule that turns all of a list of lights on at sunset" and it will do it. Again, still testing but I will follow up with results.
I would really not take this approach -- exports/imports aren't meant to be edited, and the chances of AI "knowing" internal setting names and other app data (which is what this contains -- not anything in the developer docs you fed the model) that an RM rule might use are low. This could lead to corrupted rules or other problems.
A better approach, if you want to do this, would be to ask it to write a regular Hubitat app instead (in Groovy). This code is intended to be user-editable, and you won't run into the above problem. You many run into others (some here have), but you're at least not building a house on sand.
I see I'm just repeating what @csteele and @bertabcd1234 just posted while I was writing this...
Why stay with rules at that point? I've played around with AI to write automations into Hubitat apps directly. It does pretty well for simpler stuff, and it is also good for creating virtual devices if you need a virtual devices with some special feature.
It is a good way to start learning groovy for apps code. AI gets you most of the way there, but you should understand what it is doing. I still write my automation apps from scratch, but it has been fun playing with AI to see how it approaches writing the code.