Does it do this with a full battery, or only when the battery level is low? Have you cleaned the battery and battery socket contacts? Are the batteries a little loose or do they rattle? Have you used dielectric grease on the contacts?
I've also got a Roadster which, although it doesn't have many miles and doesn't get ridden in the rain, does not exhibit this characteristic. I do not have the throttle.
When I first got the bike I would have some issues with the display going blank, and total motor cut-off. I sprayed some contact cleaner into the plugs/sockets going into the display and haven't had recurrence of this issue lately.
Do you get the same "pumping the gas pedal" if using the throttle only? Might point more to the torque sensor if it doesn't happen with throttle only.
I had a similar issue with a Bosch mid-drive, but it only seemed to happen when the battery was 2-3 bars or lower. Cleaned everything up, but still happened some. Battery didn't seem overly loose, but I put a short (4") piece of self-adhesive weatherstrip foam under the battery and the issue has never happened again.