Hello and welcome to Just answer.com, Super mechanic here. Please DON’T hit accept until you are completely satisfied with the answer. About your vehicle.
The adaptive presets have to be relearned. That can be done with a scan tool, (that the dealership uses) or by normal driving. That happens a lot with them if the battery is disconnected. You can try going through a drive cycle and then it should idle normally.
THROTTLE BODY CLEANING NOTE: Disconnect the intake air hose from the throttle body, and check the throttle valve surface for dirt. Spray cleaning solvent on the lace of the valve to remove dirt.