Foundation of Generative AI