Artificial intelligence (AI) has enormous value but capturing the full benefits of AI means facing and handling its potential pitfalls.