I was betting it was the CPS, as mine did the same thing last year, it would also die randomly at stop lights Lol.
But yeah, I replaced everything to start fresh, Cam/crank sensor, CTS, Knock sensor.
You need to do plugs and wires on that too, Why didn't we do them when we put the motor back in?