fungi traditionally used for making alcoholic beverages in China and Korea for a long time were fungi belonging to Rhizopus and Mucor, whereas in Japan, except in the early days, the fermented food fungus used for sake brewing was Aspergillus oryzae. Some scholars believe the Japanese domesticated the mutated, detoxified Aspergillus flavus to give rise to Aspergillus oryzae. In the Heian period (794–1185), sake was used for religious ceremonies, court festivals, and drinking games. Sake production was a government monopoly for a long time, but in the 10th century, Buddhist temples and Shinto shrines began to brew sake, and they became the main centers of production for the next 500 years. Muromachi period Before the 1440s in the Muromachi period (1333－1573), the Buddhist temple Shōryaku-ji invented various innovative methods for making sake. Because these production methods are the origin of the basic production methods for sake brewing today, Shoryakuji is often said to be the birthplace of (). Until then, most sake had been with a different process from today's, but after that, clear was established. The main production methods established by Shōryaku-ji are the use of all polished rice (morohaku zukuri, 諸白造り), three-stage fermentation (sandan zikomi, 三段仕込み), brewing of starter mash using acidic water produced by lactic acid fermentation (bodaimoto zukuri, 菩提酛づくり), and pasteurization (hiire, 火入れ). This method of producing starter mash is called bodaimoto, which is the origin of . These innovations made it possible to produce sake with more stable quality than before, even in temperate regions. These things are described in (), the oldest known technical book on sake brewing written in 1355 or 1489, and (), a diary written between 1478 and 1618 by monks of Kōfuku-ji Temple in the Muromachi period. A huge tub (:ja:桶) with a capacity of 10 koku (1,800 liters) was invented at the end of the Muromachi period, making it possible to mass-produce sake more efficiently than before. Until then, sake had been made in jars with a capacity of 1, 2, or 3 koku at the most, and some sake brewers used to make sake by arranging 100 jars. In the 16th century, the technique of distillation was introduced into the Kyushu district from Ryukyu. The brewing of shōchū, called "Imo–sake" started and was sold at the central market in Kyoto. Edo period By the Genroku era (1688–1704) of the Edo period (1603–1867), a brewing method called () was