Get an electrician to get all the wirin' in order.
What do you mean "won't go past 4500 RPMs"? As in, does it act as if the rev limiter is at 4500 RPMs?
if it does, then it might be your Air Flow Sensor which is weak, dirty or 'bout to die. 'Cause if it, the Air Flow Sensor, is not connected, the 3S engine can't go past 3000 RPMs.
Hope this info helps.
Toyota Altezza 1999 - White
Done up by Team 5Zigen in Japan