Records of the Three Kingdoms
Sima Yi, courtesy name Zhongda, was from Wen in Henei. When Cao Cao summoned him he pleaded illness. Later he was forced into service and became a man at Cao Pi’s side. Under Cao Pi and Cao Rui his military and civil rank kept rising.
At Jieting, during Zhuge Liang’s northern campaigns, the Wei commander on the spot was Zhang He. Sima Yi’s direct confrontation with Zhuge Liang belongs mainly to the later expeditions, above all Wuzhang in 234. He held and would not fight. Zhuge Liang sent women’s clothes. Sima Yi still did not come out. After Zhuge Liang’s death he advanced and was driven back by the Shu army. People said the dead Zhuge put the living Zhongda to flight. The saying is in a work Pei quotes.
In 249 the Cao Shuang brothers went with the emperor to Gaoping Tombs. Sima Yi shut the gates of Luoyang, memorialized to dismiss Cao Shuang, and then exterminated the faction. He did not become emperor in his lifetime. His posthumous title was King Xuan. After Sima Yan founded Jin he was titled Emperor Xuan.
Romance of the Three Kingdoms
The novel thickens the contest of wits with Zhuge Liang, including the empty fort. The empty fort is not in Chen Shou, and Pei Songzhi rejected a story of the same kind.
The fire at Shangfang Gorge, and the sons holding him back from pursuit, are the novel. The coup itself is written close to the histories: he feigns illness, then shuts the gates when Cao Shuang leaves the city.
Reference: Wikipedia · Sima Yi