I am very interested in knowing how the Quran was actually compiled. I hear many say that Abu Bakr, umar, or uthman compiled it with the help of a guy named Zaid bin Thabet. But these hadiths are so conflicting and all contradict each other. And also I believe the Prophet would never leave without having compiled the greatest miracle of all time. The prophet wouldn't just leave them on scatered leafs for the caliphs to combine later. I think the Prophet had the book compiled before he passed away. Even in hadith thaqalin, he stated he left behind the book of Allah and ahlulbait. He said book, meaning there was a book. Even other hadiths that mention when jibrael would come, he would say place such and such in this surah for example. There was obviously a book right? The conflicting hadiths about some caliph compiling it don't sit right with me. Especially the idea of if they had 2 witnesses, they add the verse. I even read part of sayid Khoei's book and it mentions that those hadiths are contradicting and the Prophet of course left a book behind. But Im a little confused because it seems that most agree that caliphs compiled them.

1- The Qur’an was not in a fully compiled form during the life of the Prophet (s). There was a copy of the Qur’an in the Prophet’s mosque, but it wasn’t fully compiled. It was more scattered pages put together. But it was still in book format.

2- As soon as the Prophet (s) passed away, Imam Ali (a) compiled those pages into one organized book. It took him about 3 days to do that.

3- During the time of Uthman, different versions of the Qur’an had appeared (due to different ways of writing the Arabic script), and so Uthman (after consulting Imam Ali and other companions) unified the versions. He destroyed other versions and kept one only.