I bought a used I/O board on ebay for $30. Replacing the i/o board solved my problem with the "fan stack" heat sensor which had been unreadable and causing the computer to run very slowly and the fan to run full speed. It was listed like this:
2012 13" MacBook Air MagSafe II DC audio I/O Power Board A1466