Wei Xuantong

He was from what would eventually become Ding Prefecture (定州, roughly modern Baoding, Hebei), and his grandfather Wei Shikuo (魏士廓) had served as a general for Northern Qi.

By 664, he was serving as the director of performance reviews at the ministry of civil service, when, on account of his friendship with the chancellor Shangguan Yi, who had been executed after unsuccessfully trying to persuade Emperor Gaozong to depose his powerful wife Empress Wu (later known as Wu Zetian), Wei was exiled to the Lingnan region.

Early in Emperor Gaozong's Shangyuan era (674–676), there was a general pardon, and Wei was recalled to the capital.

Wei was subsequently made the secretary general of Qi Prefecture (岐州, roughly modern Baoji, Shaanxi), and then the deputy minister of civil service.

Around this time, Wei also submitted a lengthy petition to Emperor Gaozong, advocating a major reform of the civil service system.

At this time, Zhou Xing, the magistrate of Heyang County (河陽, in modern Jiaozuo, Henan), had become known for his abilities, and was summoned to the capital, as Emperor Gaozong was considering promoting him.

By 685, he was serving as one of the secretaries general for the executive bureau of government (文昌臺, Wenchang Tai), when he was made Luantai Shilang (鸞臺侍郎), the deputy head of the examination bureau (鸞臺, Luan Tai), and he was given a more honored designation as chancellor de facto, Tong Fengge Luantai Sanpin (同鳳閣鸞臺三品).