Pulses of signals in the terahertz region are generated using an apparatus made up of a mode-locked semiconductor laser diode with a short duty cycle that is optically coupled to a biased Auston switch. The output from the mode-locked semiconductor laser diode may first be supplied to a pulse compressor, and the resulting compressed pulses supplied to the Auston switch. Preferably, the mode-locking of the semiconductor laser diode is controllable, i.e., it is an active mode-locking semiconductor laser, so that the phase of the output optical signal from the laser is locked to the phase of an input control signal.