We investigate the effect of phenomenological relaxation parameters on the third-order optical nonlinearity of doped graphene by perturbatively solving the semiconductor Bloch equation around the Dirac points. An analytic expression for the nonlinear conductivity at zero temperature is obtained under the linear dispersion approximation. With this analytic formula as a starting point, we construct the conductivity at finite temperature and study the optical response to a laser pulse of finite duration. We illustrate the dependence of several nonlinear optical effects, such as third harmonic generation, Kerr effects and two photon absorption, parametric frequency conversion, and two-color coherent current injection, on the relaxation parameters, temperature, and pulse duration. In the special case where one of the electric fields is taken as a dc field, we investigate the dc-currentand dc-field-induced second-order nonlinearities, including dc-current-induced second harmonic generation and difference frequency generation.