Artificial intelligence to test customer loyalty