While it is quite common that mines are visited by some kind of mining train or tram, it is quite exceptional for caves. The main problem with caves is that they have narrow or low sections or narrow twists which make the construction of trains impossible or require a high amout of mining to build such a thing. Also there is the problem of nature protection, as such vehicles produce some kind of pollution, even if they are powered by electricity. Nevertheless there are few huge cave systems which use such a tram.
Probably the first cave with such a system was the Postojna Cave in Slovenia. The cave system is quite extensive and to reach the most interesting part of the cave, a hike down a 2.5km long level passage would be necessary. With the sightseeing part and the way back this would be a walk of 6.5km, far too much for most visitors. So the the Chairman of the Cave Commission, Dr Anton Globočnik, decided to build a train into the cave which was opened to the public in 1872. Despite leveling the floor of the passage there was the need to cut a tunnel into a fallen stalagmite, which is quite spectacular and a famous picture of the cave. At first the wagons were pulled by the guides, so every guide had two carriages called Phaetons with four seats each. The train was completely renovated in 1923 and the Phaetons replaced by a gasoline-powered locomotive with wagons for 20 visitors. From 1956 electric locomotives were used. The locomotives are common mine trians, the waggons are cutom made with benches for the visitors.
While mining trains at least are a comon technology for undergroud mining, there a some quite exotic trams installed in caves. In Fantastic Cavern in USA and in Harrington's Cave in Barbados a thing called tram is used, which is actually a car which pulls a sort of wagon for the visitors. Such wagons are rather common outside, especially for city tours and theme parks. The tires are soft and its more comfortable and less noisy. Also no rails are needed.