If it's injected some have had issues with the injector wires not making contact when the engine warms up. Try the wiggle test of the wires when you encounter the problem.
Try cleaning the IAC as well. https://www.youtube.com/results?search_query=harley+iac+cleaning
I would start with the fuel filter, (and if fuel injected, ) also when the fuel tank is down to 1/4 remove the filler cap, cycle the ignition to run and watch for fuel spray inside the tank.
The convoluted fuel lines would leak inside the tank leading to a lean condition and cause your symptoms.