Why is my alternator wire to battery melted in half at the alternator?

There must be too much amperage going through the wire. Either it's the wrong gauge wire (unlikely), or there is a problem where the charging system is putting out too many volts/amps. Check it with a multimeter.