Imam Ali (AS) did not help any of three caliphs in their deeds which was not according to the Quran and the real teachings of the Prophet Mohammad (peace be upon him and his Holy Progeny).
He rectified dangerous mistakes and wrong rulings which they wanted to do against the teachings of the Quran and Sunnah because of their lack of knowledge.
His rectification saved victims from wrong punishments and the caliphs said that without Ali we would have been doomed.
Abu Bakr said: Without Ali, Abu Bakr would have been doomed.
This is narrated in Sunni book Faydh Al Qadir.
فيض القدير Volume 4 page 357.
Omar also said: Without Ali, Omar would have been doomed.
This is narrated in many Sunni books including al Mustadrak by Al-Hakim al-Nisaboori, Volume 2 page 429.
Othman also said: Without Ali, Othman would have been doomed. This is narrated in Zaynul Fata fi soorati hal ata, Volume 1 page 317.
Imam Ali (AS) did not approve the government of any of the three caliphs but his responsibility was to guide those who asked him for guidance. And when the three caliphs asked him in spec4fic cases, he replied to them and by replying to them he saved the Muslims from wrong punishment, as three of them wanted to punish people in the wrong way. The three Caliphs admitted that without the guidance of Ali they would have been doomed.
That does not mean at all that Ali (AS) approved the government of any of the three caliphs. He was very clear that the three caliphs of Saqifah have taken his own right, his own status as the real successor of the Prophet (SAWA) but he kept his patience for the sake of the Ummah and for the sake of Islam.
Those who want to know the real stand of Amirul Momineen Ali (as) regarding the three caliphs should read the famous and authentic sermon called Shaqshaqiya which is mentioned in Nahjul Balagha and in many other books.
In Shaqshaqiya sermon Imam Ali (AS) made it very clear that Abu Bakr, then Umar and then Othman were not entitled to take the post which they have taken, but for reasons they took what they have taken, he kept patient only for the sake of the safety of Islam and the Muslim Ummah.
In Saheeh Muslim, (volume 5, page 153), Omar admitted to Ibn Abbas, that Ali believe that Abu Bakr are Umar were wrong in claiming caliphate after the Prophet.