State-sponsored hacking groups from Russia, China and other U.S. adversaries have been caught using OpenAI’s tools to better attack their targets, amid concerns of possible cybersecurity threats as AI technology improves.