it is not certain if its members originally arrived in Japan from Silla, as textual sources preserve traditions about the clan's arrival from Paekche or alternatively about its descent from Chinese emperor Xian of Han. Reconstruction of the early history of Shinra Myōjin is complicated by the small number of surviving records from Onjō-ji predating the Muromachi and Edo periods. While according to the temple's tradition a statue representing Shinra Myōjin was already made by Enchin in the ninth century, there is no other evidence supporting this notion. The oldest reference to him occurs in a document from 971. The first known priest of his shrine was a certain Kiyomura (淸村) from the Ōtomo clan in the tenth century. Various rituals were held in his honor regularly between the eleventh and thirteenth centuries. One of them was known simply as the Shinra Myōjin festival (新羅明神祭礼, Shinra Myōjin sairei), and was first held by Myōson in 1052. Shinra Myōjin reportedly revealed to this monk an oracle that he will act as the protector of the local clergy. While initially only monks took part inhis festival, it eventually became one of the largest public celebrations held in Onjō-ji, with a particularly well documented parade involving eleven portable shrines (神輿, mikoshi) taking place in 1210. Other examples of rituals focused on Shinra Myōjin include the Thirty Lectures of the Shinra (新羅三十講, Shinra sanjūkō), possibly a series of lectures focused on the Lotus Sutra, first held in 1202; the Shinra nenbutsu (新羅念仏), first held in 1109 and most likely focused on the recitation of Shinra Myōjin's name to invoke him for the sake of healing and securing longevity, as well as a variety of ennen (延年) celebrations, similarly focused on guaranteeing longevity. Up to the fifteenth century, members of the Ōtomo clan were the only people maintaining the shrine of Shinra Myōjin, and Shinra Myōjin ki (新羅明神記) credits them with the continuous transmission of his secret rites. However, from the eleventh century onward their power declined, and the Seiwa Genji (清和源氏) branch of the Minamoto clan came to be associated with the Jimon tradition of Tendai as well. Shinra Myōjin came to be regarded as their tutelary deity following the Former Nine Years' War, within Minamoto no Yoriyoshi’s lifetime (988-1075). Reportedly he swore that if victorious from this conflict, he would dedicate one of his sons to Onjō-ji. Subsequently the shrine of Shinra Myōjin