Text this: Optimized power dispatch for smart building(s) and electric vehicles with V2X operation