Researchers have developed a security solution for power-hungry AI models that offers protection against two common attacks.