He returned to Cambridge, to the Sub Department of Animal Behaviour in 1970, and there met Dian Fossey, who invited him to spend three months at her gorilla study camp in Rwanda. His experience with the gorillas, and a subsequent visit to Richard Leakey's field-site on Lake Turkana, set Humphrey thinking about how cognitive skills – intelligence and consciousness – could have arisen as an adaption to social life. In 1976 he wrote an essay titled "The Social Function of Intellect", which is widely regarded as one of the foundational works of evolutionary psychology and the basis for Machiavellian intelligence theory. This paper formed the basis of his first book, "Consciousness Regained: Chapters in the Development of Mind" (1983).