Mysterious Power Loss

I have a 2006 GEM XL. About 6 months ago, I began to have a problem with a loss of power after about 10 min of driving. The will go from full power 20-24 mph to 6-8 mph and ultimately come to a stop. If I turn the key off for 30 min or so, the cycle will begin again. I originally thought this must be a battery issue. I have removed all of the batteries (only 18 months old) and tested them, charged them individually, and cleaned the battery terminals and cables. I have put a lead on to watch voltage drop and not seen anything out of the ordinary. Typically battery voltage is 78-76v and hold relatively constantly. I am now wondering if this is a motor or controller issue. It has thrown some codes in the past (unfortunately I neglected to notate them), but doesn’t do so regularly or when the loss of power occurs. What should be the next step in diagnosing what is going on? We absolutely love the car and it is a must have around our house. Thank you in advance I look forward to getting her back.