Wenyi became a Buddhist monk by the age of 7. His first tutor was Quanwei Chanbo. He followed monk Xijue to the Ashoka temple of Mingzhou where Xijue and Wenyi preached. He then traveled to the southern city of Fuzhou in search of the solution of his doubts on the subject of Zen. In Fuzhou, Wenyi's knowledge gained him much popularity. However, he was not content with himself and thought that he had not detached himself from the secular world. His departure from Fuzhou eventually led him to Linchuan. The tradition of Zen Buddhism holds that it was during this particular trip, Wenyi acquired great insight(頓悟). Knowing that Wenyi is an accomplished Zen philosopher, the king of Nan Tang which ruled over the Linchuan region appointed a temple under his guidance. He would remain in the kingdom of Nan Tang for the rest of his life, promulgating the way of Zen. Wenyi died in the year 958. The King of Nan Tang ordered his royal subjects to wear white clothes for the mourning of Wenyi's death. A pagoda was built in Danyang in honor of Wenyi's spiritual accomplishments. His posthumous title "Zen master Dafayan"(大法眼禪師) was then granted.