There are several trains daily that make the 9 hour trip from Taraz to Almaty starting at around 07:00. All or most of the coaches are triple-deck sleepers.
The train station in Taraz is at Map Location: 42.870171, 71.378996 . It isn't far from the center of Taraz and several buses go by the station.
In Almaty, the train arrives at the Almaty 1 train station at Map Location: 43.341145, 76.948877 . Taxis to the center of Almaty cost around 1500 to 2000 tenge. The taxi drivers will try to charge much more.