one origin is about li deyu. he was an officer in tang dynasty. after demoted by the court, he kept travelling and had been chicken island. after his visit, people built a temple for him and exalted him as spirit. when ships went by, sailors would go to the temple and worship his spirit by releasing a chicken.