It would be a lot easier to answer your questions and help you if you would provide some documentation. A schematics diagram could be a good start. Also, how you constructed it (on a circuit board, "wiring in air", or whatever). Maybe you could even add a photo or two?
In general terms, I can say, however, that the problem might be related to transients generated by the AC motor. In such situation good by-passing power supply, having correct grounding, maybe some shielding of wires/circuitry, and avoiding of "magnetic pick-up loops" in sensitive places of the wiring are usually necessary for reliable operation: You got a significant source of noise and spikes in the sparking relay contacts switching an inductive load (the motor)!