The current digital media have problems such as ambiguous communication orientation, uneven content quality and stereotyped discourse patterns, which not only affect the communication effect of the media, but also limit its sustainable development. This study explores the application strategy of deep generative model in digital media content generation and communication effect optimization. The study proposes a variational digital media content generation model based on adversarial training (VAE-IAT), which combines the advantages of variational self-encoder and generative adversarial network to realize the generation of high-quality digital media content through the collaborative work of three modules, namely, encoder, generator, and discriminator; and at the same time, it constructs three optimization paths to enhance the communication effect, including improving communication precision, deepening content production, and strengthening the interaction with the audience. The experiments are conducted with three datasets: MNIST, SVHN and CelebA, and the results show that the VAE-IAT model exhibits excellent generation ability on all three datasets, and the FID scores are maintained below 6, which is significantly better than that of the control model. The results of the dissemination effect validation experiment show that the experimental group reaches significant differences with P-values of 0.002, 0.007, 0.003, and 0.005 for the four dimensions of media comments, media retweets, media interactions, and media likes, while the control group does not show any significant differences. The results of the study confirm that the digital media content generation technology driven by deep generative model can effectively improve the quality of content, and the communication optimization path constructed based on it can significantly improve the communication effect of digital media, which provides new technical support and theoretical guidance for digital media content creation and communication strategy.