AI-driven energy system