The Gemara in Bava Kama starting at 83b discusses th issue at great length, bringing numerous sources for the non-literal understanding of the Pasuk. Besides those mentioned in the Gemara, later authorities brought many more hints from the text of the Torah that the pesukim refer to monetary payment. It would be too lengthy of a discussion to quote them all here.
Importantly, the Rambam in his introduction to his explanation of the Mishna deals with this subject. There he writes that there was always a known and undisputed direct tradition that the verses were non-literal. The purpose of the exegesis of the Gemara is not to learn the otherwise-unknown meaning of the pesukim. Rather, it is to demonstrate that all the details of the Oral Torah are hinted to in the text of the Written Torah.
The Rambam compares this to the Gemara in Succah (daf?), which seems to be unsure about what fruit the Torah refers to in the commandment of the Four Species taken on Sukkos. Like in Bava Kama, different Sages offer drashos and pesukim to show that the Pasuk refers to the esrog. Now, says the Rambam, it was undoubtably known throughout Jewish history that the fruit taken on Sukkos is the esrog. Did the Sages not see there parents and communities taking esrogim every year? Thus, writes the Rambam, these pesukim must not be seen as the source for the law, but as the hint to the law that can be found in the Written Torah.