The thermocouple is a cheap first step I agree. If the pilot light continues to extinguish, then the quality of the flame is probably not sufficient to tell the gas valve (through the thermocouple signal) - that the pilot light is lit - even if the flame is blue. Just take a Q-tip with some alcohol and clean the flame nozzle (shaper) to remove carbon build up from the orifices - doesn't take much - and the flame will be hot enough to signal a lit pilot light. I'm 0 for 3 on thermocouples.