DIAGNOSIS Engine surging is almost always a fuel delivery problem. The carburetor is getting inconsistent fuel, typically due to a blockage or water.
FIX First, drain the fuel tank and carburetor bowl completely. Use the fuel valve and the drain screw on the bottom of the carburetor bowl. Refill with fresh, ethanol-free 87 octane gasoline. Add a fuel system cleaner like Seafoam to the tank. Run the generator under a 50% load for 30 minutes. This may clear minor blockages.
IF THAT DIDN'T WORK The main jet or the emulsifier tube in the carburetor is partially clogged. The carburetor must be removed, fully disassembled, and cleaned with aerosol carb cleaner and compressed air. Pay special attention to all small fuel passages.
HEADS UP Surging can also be caused by a vacuum leak. Check the carburetor mounting gasket and the intake manifold connection for cracks or looseness after cleaning the carburetor.