Cities and countries already have begun to deploy AI and ML technologies for public safety and security. On one hand machine learning applications in image and video recognition can help law enforcement officials in detecting criminal activities and efficiently prevent acts that endanger public safety. On the other hand, without thoughtful safeguards, the misuse of these technologies by law enforcement poses sobering human rights risks. Using SenseTime as a case study, this article discusses how China's most valuable AI company, SenseTime, has partnered with government authorities to accelerate product development, why its partnership with the Chinese state is potentially problematic, and how the company can safeguard itself from the misuse of its product.