A bad TPS usually causes acceleration and auto transmission shifting issues.
Sounds like you need a new battery.
For 1997-2001 (and maybe 1996) OBD-II the engine computer (ECU or PCM) re-boots and the idle settings are deleted when: (1) you let the battery rundown by leaving the lights or radio on, (2) disconnect the battery for an extended period of time, (3) or when the battery goes bad and needs replacing.
Your symptoms are; difficulties starting the engine without depressing the gas pedal, and the engine will have low idle and will probably stall unless you keep your foot on the gas pedal.
The ECU will relearn the idle settings after a short period of time and the engine will start and idle normally. If the symptoms reoccur, you need to have your battery load tested at a repair shop or auto parts store. Even with low battery voltage, the engine will start, but the ECU can re-boot multiple times and a new battery may be required.
Loose, corroded, or damaged battery cables or ground wires may also cause or contribute to the problem. Begin with basic trouble shooting of the start and charge systems. Remove, clean, and firmly reconnect all the wires and cables to the battery, starter, and alternator. Look for corroded or damaged cables and replace as needed. Do the same for the grounding wires from the battery and engine to the Cherokee's frame/body.
Cleaning the IAC and using fuel injector cleaner should be part of your routine preventative maintenance.