Intermittent electrical issues are tough to track down. Start with the ac switch. Try bypassing it with a jumper wire and see if the AC stays on all the time. If its not the switch you are going to have to look at _all_ the AC circuits electrical connections. Won't be fun so start in the engine compartment where they are subject to the elements.
_________________________
Original owner 2000 X