Bacterial communities are highly susceptible to fluctuations in amino acid content. To investigate the response of microbial communities in daqu to environmental perturbations, we employed high-throughput sequencing and statistical analyses. Samples were collected from two workshops (A and B) at distinct stages of daqu fermentation and storage. Our analysis, using the β-nearest taxon index (βNTI), revealed that fungal community assembly is shaped by both stochastic and deterministic processes. In contrast, bacterial communities exhibited a shift towards deterministic assembly under environmental stress, with fluctuations in amino acid content being a primary driver. Notably, communities with active amino acid metabolism displayed a greater involvement of stochastic processes and harbored a higher number of bacterial keystone taxa, which contributed to the stability of microbial networks. This study provides novel insights into the complex interplay between microbial communities and their environment in the context of daqu.