I would isolate the circuit that is causing the problem. Start by disconnecting circuits going to the headlight switch, headlight, tail lights, interior lights, anything powered by the headlight switch, until the yellow wire stops overheating. Then troubleshoot the circuit that causes the wire to overheat. I suspect you have a wire somewhere partly grounded OR possibly a bad ground that is using another circuit as a ground (back feeding through the headlight switch).