According to the ancient, presumed historical and regarded as accurate with some fantastic embellishments, record "Nihon Shoki", the festival originated during the reign of Emperor Kinmei (reigned CE 539 - 571). The ancient records known as the "Honchō getsurei" (本朝月令) and "Nenchūgyōji hissho" (年中行事秘抄) reveal that a succession of disastrous rains with high winds ruined the grain crops, and epidemics had spread through the country. Because diviners placed the cause on divine punishment by the Kamo deities, the Emperor sent his messenger with a retinue to the shrine to conduct various acts to appease the deities, in prayer for a bountiful harvest. These included riding a galloping horse.