You are looking for something other than an artificial intelligence there & rocketing towards artificial sentience sapience or artificial consciousness which is far beyond what HAL & nearly every other fictional AI.If HAL does not have free will, he isn't an artificial intelligence and isn't germane to the topic of this thread.
edit: hal was limited to the confines of his operating parameters.