I have a fan device as well that’s basically the same thing, used Claude to hack local Tuya to make sleep timers and color light dimming work without the cloud integration. Side effect is also that it’s instantaneous rather than super laggy like it was with cloud.