While there isn't much in the fossil record to learn how humans became so intelligent, only that they did, or even to indicate the development of the evolution of the vertebrate nervous system. A look at comparative anatomy sheds some light on the subject; at least on the evolution of the vertebrate brain.
For example, if one looks at the nervous system of the lancelet, while not a vertebrate it is still a chordate, it has a lump of neurons at the end of the notochord, not a true brain mind you, but it provides a glimpse at the early vertebrate nervous system. Lampreys are a far bette example, given that they are true (albeit basal, if you'll pardon my usage of the expression, John) vertebrates. For example, according to Baramov et al. (2016), a specific gene the lamprey possesses provides a key clue to the "origins of telencephalation", or, in layman's terms, aka language that is not needlessly complicated while still getting the message across, the origins of the brain.
[quick note: for the record I am aware that some scientific concepts can only accurately be described in technical terms]
Baramov hypothesizes that the Anf homeobox gene played a key role in the development of the vertebrate brain based of homological evidence I will discuss here. Invertebrate and vertebrate early embryonic development of the brain rudiment are remarkably similar, however, where they diverge is that the Anf gene is absent from every single invertebrate on this planet, and is only found in vertebrates, including lampreys. According to the hypothesis provided by Baramov et a, the appearance of the Anf variant gene in the LCA of all vertebrates is related to, and perhaps caused, the appearance of the telencephalon.
Nature Article - The article isn't paywalled, if any of you were wondering.