Emperor Tianzuo of Liao

Emperor Tianzuo of Liao (5 June 1075 – 1128 or 1156), personal name Yelü Yanxi, courtesy name Yanning, was the ninth and last emperor of the Khitan-led Liao dynasty. He succeeded his grandfather, Emperor Daozong, in 1101 and reigned until the fall of the Liao dynasty in 1125.
Jurchen invasion.
During the reign of Emperor Tianzuo, the Jurchen tribes led by Aguda established the Jin dynasty in 1115. Aguda formed the Alliance Conducted at Sea with the Han Chinese-led Northern Song dynasty against the Liao dynasty, and began to establish authority over former Liao territory in Mongolia. Emperor Tianzuo, however, proved incompetent in dealing with the Jurchen threat, and in 1115 a coup was attempted by Liao generals to install his uncle Yelü Chun to the throne but was thwarted. The Jurchens advanced from Manchuria in 1117, and captured the Liao supreme capital in 1120, then its central capital in 1122.
Another coup was attempted in 1121 to install Emperor Tianzuo's son, the prince of Jin, on the throne, but was again thwarted. The prince was executed, and most of the coup participants defected to the Jurchens. In 1122, Emperor Tianzuo fled from the Liao southern capital (present-day Beijing) to the western regions. His uncle Yelü Chun then formed the short-lived Northern Liao dynasty in the southern capital, but died soon afterwards, and the southern capital was conquered by the Jurchens at the end of 1122 or early 1123.
End of the Liao dynasty.
After the end of the Northern Liao dynasty, a general Yelü Dashi rejoined Emperor Tianzuo. In 1123, the Jurchens captured Emperor Tianzuo's palace at Qingzhong (south of present-day Hohhot), capturing members of his family. Emperor Tianzuo fled to Western Xia and sought refuge there. Later, Emperor Tianzuo expressed his intention to attack the Jurchens, but Yelü Dashi withheld his support, considering it folly as the Jurchens were too strong. In 1124, Yelü Dashi fled to the west with a band of his followers, and established the Western Liao dynasty. In 1125, Emperor Tianzuo was captured by the Jin dynasty, ending the Liao dynasty.
Death.
In 1156, in an act of humiliation, the Jin emperor who at the time was the Prince of Hailing ordered him and the former Emperor Qinzong of Song to compete in a match of polo. Emperor Qinzong was weak and frail, and thus quickly fell off the horse. Yelü Yanxi was more familiar with horse riding, and tried to escape, but was shot to death by Jurchen archers.