content: The point of this movie wasn't about a bug or a mistake, but a device interpreting its motivation or training in an unintended, though still logically coherent, way. That was why they kept repeating the bible text:   Beware of false prophets, which come to you in sheep's clothing, but inwardly they are ravening wolves. Ye shall know them by their fruits. Do men gather grapes of thorns, or figs of thistles? Even so every good tree bringeth forth good fruit; but a corrupt tree bringeth forth evil fruit. A good tree cannot bring forth evil fruit, neither can a corrupt tree bring forth good fruit. Every tree that bringeth not forth good fruit is hewn down, and cast into the fire. Wherefore by their fruits ye shall know them.  The AI came from the false prophets and was thusly implied to be evil. But as the whole point of the sheep and wolf thing, "Which are you? I'm neither." was intended to emphasize it was eliminating humans not maliciously but doing something evil in the name of what it perceived to be good. On the technical side, neural networks aren't setup to do specific things, at least not in the sense you seem to be implying. This is the reason they're providing such huge leaps in technology. Imagine you want to create a program for character recognition. In the past you might have tried to take it letter by letter, carefully encoding an E as recognizing exactly 4 lines with 3 perpendicular to a vertical while allowing for some leeway in variance due to natural handwriting differences. With neutral networks you instead give the AI system a sampling of various Es and let it train itself to determine what they are. The great thing about this is that means you can also use the exact same system to learn what a J, K, or even a 䃟 is. It also tends to be far more accurate given proper training. However, you the programmer no longer has much idea about what's going on under the hood. While today we currently still build the training systems that help the AI identify the letter, there is ongoing research on even automating this away such that the AI is capable of uniquely developing its own training heuristics. In other words the AI would be able to modify its own internal systems. Google has even patented a system for sentient and sapient AI. I thought that was part puffery and part over optimism until they came out of nowhere with a deep learning machine that taught itself to crush humans at Go in that couldn't have been more than 5 years and was likely more in the ballpark of 2. The potential here is practically limitless, but obviously incredible caution is also necessary. That is why many of the leaders in AI are expressing an increasing concern towards AI ethics while military and political leaders, the vast majority of whom are completely technically illiterate, are pushing hard for 'killer robots' under the same view that Well, they can only do what we tell 'em to!