# Yang Liangyao

Yang Liangyao (Chinese: 楊良瑤) was a Tang dynasty eunuch official known only from his tomb stele, discovered in 1984. He had a long and distinguished career at the Tang court, and led a number of embassies, most notably to the Abbasid Caliphate in 785.

## Life

Yang Liangyao is not attested in any surviving history or other written source, apart from a stele that was discovered in 1984 at Xiaohuyang village in the Yunyang District of Jingyang County, Shaanxi Province. The stele is now located in the Jingyang County Museum. The inscription records his origin and career. His great-grandfather had been a Tang general who had assisted Emperor Xuanzong (r. 713–756) overthrow the tutelage of Empress Wei.
Yang Liangyao himself entered court service as a eunuch in the first years of Suzong's reign (756/757). In 765/766 he was promoted after helping suppress a revolt to supervisor of some of the female sections of the palace, and again to the position of Assistant in the Palace Gates Service in 771. He then served as commissioner to Annan, followed in 774 by a mission to Guangzhou. There he was captured by the rebel Geshu Huang, and remained in captivity until the rebellion was defeated in 777. Yang was promoted Director of the Palace Gates Service as a reward for his steadfastness during his captivity.
Following the rebellion of general Zhu Ci in 782 and the capture of Chang'an by the rebels, in 784 Yang was sent in embassy to the Tibetan Empire to seek military support, in exchange for ceding the provinces of Anxi and Beiting. The mission was successful, and Yang returned to China along with the Tibetan troops. The Tibetan intervention was crucial in saving the Tang regime and defeat Zhu Ci. As a reward, he was named Executive Assistant of the Palace Domestic Service, and the rank of Grand Master for Closing Court.
In the next year, he led an embassy to the Abbasid Caliphate via sea from Guangzhou, and was back at Chang'an in mid-788, when he was honoured as Grand Master of the Palace, and given the rank of baron of Hongnong District, with 300 households attached to his service as an appanage. His mission to the Abbasids was most likely related to the imminent conflict with the Tibetans in the aftermath of the defeat of Zhu Ci, when the Tang court refused to honour itsword and cede the two provinces to the Tibetans. The Tang strategy, as articulated a couple of years later by chancellor Li Bi, was one of allying with the Tibetans' neighbours—the Abbasids, the Uyghur Khaganate, Indian powers, and Nanzhao—and attacking Tibet from all sides.
In 796, he was further promoted to Superior Master of the Palace. Three years later, he was appointed to suppress the revolt of Wu Shaocheng in Huaixi, which he did successfully through a judicious mixture of infiltrating spies among the rebels to learn their intentions, and offering them pardon and recruitment into the Imperial army. In his later life, he converted to Buddhism and made donations of land and money to Buddhist monasteries, commissioned copies of scripture, and founded Buddhist temples. His last acts at court were in 805, when he was tasked with inspecting the Three Troops of the Right. He died in 806 at Chang'an, at the age of 71.